UNPKG

next-i18next

Version:

The easiest way to translate your NextJs apps.

34 lines 799 B
const DEFAULT_LOCALE = 'en'; const LOCALES = ['en']; const DEFAULT_NAMESPACE = 'common'; const LOCALE_PATH = './public/locales'; const LOCALE_STRUCTURE = '{{lng}}/{{ns}}'; const LOCALE_EXTENSION = 'json'; export const defaultConfig = { defaultNS: DEFAULT_NAMESPACE, errorStackTraceLimit: 0, i18n: { defaultLocale: DEFAULT_LOCALE, locales: LOCALES }, get initImmediate() { // i18next < 24 return typeof window !== 'undefined'; }, get initAsync() { return typeof window !== 'undefined'; }, interpolation: { escapeValue: false }, load: 'currentOnly', localeExtension: LOCALE_EXTENSION, localePath: LOCALE_PATH, localeStructure: LOCALE_STRUCTURE, react: { useSuspense: false }, reloadOnPrerender: false, serializeConfig: true, use: [] };