mirror of
https://github.com/chillpadclub/bedolaga-cabinet.git
synced 2026-07-28 09:33:46 +00:00
fix: correct locale loader type to support nested translation objects
This commit is contained in:
@@ -1,8 +1,8 @@
|
|||||||
import i18n from 'i18next';
|
import i18n, { type ResourceLanguage } from 'i18next';
|
||||||
import { initReactI18next } from 'react-i18next';
|
import { initReactI18next } from 'react-i18next';
|
||||||
import LanguageDetector from 'i18next-browser-languagedetector';
|
import LanguageDetector from 'i18next-browser-languagedetector';
|
||||||
|
|
||||||
const localeLoaders: Record<string, () => Promise<{ default: Record<string, string> }>> = {
|
const localeLoaders: Record<string, () => Promise<{ default: ResourceLanguage }>> = {
|
||||||
ru: () => import('./locales/ru.json'),
|
ru: () => import('./locales/ru.json'),
|
||||||
en: () => import('./locales/en.json'),
|
en: () => import('./locales/en.json'),
|
||||||
zh: () => import('./locales/zh.json'),
|
zh: () => import('./locales/zh.json'),
|
||||||
|
|||||||
Reference in New Issue
Block a user