Refactored localization files.
This commit is contained in:
1 parent
7c2b687350
commit
f24696de5a
124 files changed
+18
-18
No files matched your search
+2
-2
@@ -5,7 +5,7 @@ import { LOCALE_CONFIG } from 'lib/constants';
|
||||
import { getDateLocale, getTextDirection } from 'lib/lang';
|
||||
import useStore, { setLocale } from 'store/app';
|
||||
import useForceUpdate from 'hooks/useForceUpdate';
|
||||
import enUS from 'public/messages/en-US.json';
|
||||
import enUS from 'public/intl/messages/en-US.json';
|
||||
|
||||
const messages = {
|
||||
'en-US': enUS,
|
||||
@@ -21,7 +21,7 @@ export default function useLocale() {
|
||||
const dateLocale = getDateLocale(locale);
|
||||
|
||||
async function loadMessages(locale) {
|
||||
const { ok, data } = await get(`${basePath}/messages/${locale}.json`);
|
||||
const { ok, data } = await get(`${basePath}/intl/messages/${locale}.json`);
|
||||
|
||||
if (ok) {
|
||||
messages[locale] = data;
|
||||
|
||||
Reference in new issue
Block a user