i18n implementation & Login i18n

This commit is contained in:
headlessdev
2025-04-28 23:19:55 +02:00
parent 58bd039635
commit ff49825eab
7 changed files with 183 additions and 17 deletions

12
i18n/request.ts Normal file
View File

@@ -0,0 +1,12 @@
import {getRequestConfig} from 'next-intl/server';
export default getRequestConfig(async () => {
// Provide a static locale, fetch a user setting,
// read from `cookies()`, `headers()`, etc.
const locale = 'en';
return {
locale,
messages: (await import(`./languages/${locale}.json`)).default
};
});