diff --git a/public/locales/nb-NO/about.json b/public/locales/nb/about.json similarity index 100% rename from public/locales/nb-NO/about.json rename to public/locales/nb/about.json diff --git a/public/locales/nb-NO/api.json b/public/locales/nb/api.json similarity index 100% rename from public/locales/nb-NO/api.json rename to public/locales/nb/api.json diff --git a/public/locales/nb-NO/main.json b/public/locales/nb/main.json similarity index 100% rename from public/locales/nb-NO/main.json rename to public/locales/nb/main.json diff --git a/public/locales/nb-NO/model.json b/public/locales/nb/model.json similarity index 100% rename from public/locales/nb-NO/model.json rename to public/locales/nb/model.json diff --git a/src/i18n.ts b/src/i18n.ts index c032fda..ad20970 100644 --- a/src/i18n.ts +++ b/src/i18n.ts @@ -4,14 +4,16 @@ import { initReactI18next } from 'react-i18next'; import Backend from 'i18next-http-backend'; import LanguageDetector from 'i18next-browser-languagedetector'; -export const i18nLanguages = ['da', 'en', 'nb-NO', 'zh-CN', 'zh-HK', 'zh-TW']; +export const i18nLanguages = ['da', 'en', 'nb', 'zh-CN', 'zh-HK', 'zh-TW']; i18n .use(Backend) .use(LanguageDetector) .use(initReactI18next) .init({ - fallbackLng: 'en', + fallbackLng: { + default: ['en'], + }, ns: ['main', 'api', 'about', 'model'], defaultNS: 'main', });