From 273710883e4f4bf37ead54c3fc29dbded7e5fd26 Mon Sep 17 00:00:00 2001 From: bender Date: Tue, 9 Jun 2026 14:56:44 +0000 Subject: [PATCH] Add src/app/i18n.ts --- src/app/i18n.ts | 12 ++++++++++++ 1 file changed, 12 insertions(+) create mode 100644 src/app/i18n.ts diff --git a/src/app/i18n.ts b/src/app/i18n.ts new file mode 100644 index 0000000..692908f --- /dev/null +++ b/src/app/i18n.ts @@ -0,0 +1,12 @@ +import { getRequestConfig } from 'next-intl/server'; +import { notFound } from 'next/navigation'; + +const locales = ['en', 'nl', 'es']; + +export default getRequestConfig(async ({ locale }) => { + if (!locales.includes(locale as any)) notFound(); + + return { + messages: (await import(`./messages/${locale}.json`)).default + }; +}); -- 2.49.1