diff --git a/frontend/app/[locale]/layout.tsx b/frontend/app/[locale]/layout.tsx index ddf43e1f..3cd94956 100644 --- a/frontend/app/[locale]/layout.tsx +++ b/frontend/app/[locale]/layout.tsx @@ -10,7 +10,7 @@ import { CookieBanner } from '@/components/shared/CookieBanner'; import Footer from '@/components/shared/Footer'; import { ScrollWatcher } from '@/components/shared/ScrollWatcher'; import { ThemeProvider } from '@/components/theme/ThemeProvider'; -// import { getCachedBlogCategories } from '@/db/queries/blog/blog-categories'; +import { getCachedBlogCategories } from '@/db/queries/blog/blog-categories'; import { AuthProvider } from '@/hooks/useAuth'; import { locales } from '@/i18n/config'; @@ -25,18 +25,10 @@ export default async function LocaleLayout({ if (!locales.includes(locale as any)) notFound(); - // const [messages, blogCategories] = await Promise.all([ - // getMessages({ locale }), - // getCachedBlogCategories(locale), - // ]); - - const messages = await getMessages({ locale }); - const blogCategories: Array<{ - id: string; - slug: string; - title: string; - }> = []; - + const [messages, blogCategories] = await Promise.all([ + getMessages({ locale }), + getCachedBlogCategories(locale), + ]); const enableAdmin = ( diff --git a/frontend/db/index.ts b/frontend/db/index.ts index 5e76ca23..57d807e1 100644 --- a/frontend/db/index.ts +++ b/frontend/db/index.ts @@ -26,7 +26,7 @@ if (process.env.NODE_ENV !== 'test') { const IS_LOCAL_ENV = APP_ENV === 'local'; -const STRICT_LOCAL_DB_GUARD = process.env.SHOP_STRICT_LOCAL_DB === '1'; +0const STRICT_LOCAL_DB_GUARD = process.env.SHOP_STRICT_LOCAL_DB === '1'; const REQUIRED_LOCAL_DB_URL = process.env.SHOP_REQUIRED_DATABASE_URL_LOCAL; if (STRICT_LOCAL_DB_GUARD) { diff --git a/frontend/next.config.ts b/frontend/next.config.ts index a4b22934..017c8b8c 100644 --- a/frontend/next.config.ts +++ b/frontend/next.config.ts @@ -5,10 +5,6 @@ import createNextIntlPlugin from 'next-intl/plugin'; const withNextIntl = createNextIntlPlugin('./i18n/request.ts'); const nextConfig: NextConfig = { - env: { - APP_ENV: process.env.APP_ENV, - DATABASE_URL: process.env.DATABASE_URL, - }, images: { remotePatterns: [ { diff --git a/netlify.toml b/netlify.toml index a7c4d600..8c30c95f 100644 --- a/netlify.toml +++ b/netlify.toml @@ -8,3 +8,6 @@ [[plugins]] package = "@netlify/plugin-nextjs" + +[[plugins]] + package = "netlify-plugin-bundle-env"