From 00179cfeeaf1a83a2e883bc85dbb01ff67e13f9f Mon Sep 17 00:00:00 2001 From: joostdecock Date: Fri, 19 May 2023 16:40:15 +0200 Subject: [PATCH] chore(dev): Fix linter warnings in sites/dev --- sites/dev/hooks/use-navigation.mjs | 9 ++------- sites/dev/scripts/algolia.mjs | 3 +-- 2 files changed, 3 insertions(+), 9 deletions(-) diff --git a/sites/dev/hooks/use-navigation.mjs b/sites/dev/hooks/use-navigation.mjs index 9e4636da7d9..9ff55d7012c 100644 --- a/sites/dev/hooks/use-navigation.mjs +++ b/sites/dev/hooks/use-navigation.mjs @@ -1,12 +1,7 @@ -import { useContext, useEffect } from 'react' -import { NavigationContext } from 'shared/context/navigation-context.mjs' +import { useEffect } from 'react' import get from 'lodash.get' import { prebuildNavigation as pbn } from 'site/prebuild/navigation.mjs' -import { useTranslation } from 'next-i18next' import orderBy from 'lodash.orderby' -import { freeSewingConfig as conf } from 'shared/config/freesewing.config.mjs' -import { useAccount } from 'shared/hooks/use-account.mjs' -import { designs, tags } from 'shared/config/designs.mjs' /* * prebuildNavvigation[locale] holds the navigation structure based on MDX content. @@ -19,7 +14,7 @@ import { designs, tags } from 'shared/config/designs.mjs' * Note: Set 'c' to set the control level to hide things from users */ -const ns = ['account', 'sections', 'design', 'tags'] +export const ns = ['account', 'sections', 'design', 'tags'] const sitePages = () => { const pages = { diff --git a/sites/dev/scripts/algolia.mjs b/sites/dev/scripts/algolia.mjs index 9f5ee52bacb..df6616f7d2e 100644 --- a/sites/dev/scripts/algolia.mjs +++ b/sites/dev/scripts/algolia.mjs @@ -14,7 +14,6 @@ import fs from 'fs' import path from 'path' import algoliasearch from 'algoliasearch' import { unified } from 'unified' -import { remark } from 'remark' import { visit } from 'unist-util-visit' import remarkParser from 'remark-parse' import remarkCompiler from 'remark-stringify' @@ -98,7 +97,7 @@ const indexMarkdownContent = async () => { const run = async () => { if (process.env.VERCEL_ENV === 'production' || process.env.FORCE_ALGOLIA) { console.log() - //await clearIndex() + await clearIndex() await indexMarkdownContent() console.log() } else {