2025-02-09 11:02:27 +03:00
|
|
|
import localeRu from '../locales/ru.json';
|
|
|
|
|
|
|
|
module.exports = {
|
2025-02-15 19:45:37 +03:00
|
|
|
useTranslation: (_, options) => {
|
|
|
|
const { keyPrefix } = options ?? {};
|
2025-02-09 11:02:27 +03:00
|
|
|
return {
|
2025-02-15 19:45:37 +03:00
|
|
|
t: keyPrefix ? (key: string) => localeRu[`${keyPrefix}.${key}`] : undefined,
|
|
|
|
i18n: {
|
|
|
|
language: 'ru'
|
|
|
|
}
|
2025-02-09 11:02:27 +03:00
|
|
|
};
|
|
|
|
}
|
|
|
|
};
|