mirror of
https://github.com/bigcapitalhq/bigcapital.git
synced 2026-02-18 22:00:31 +00:00
fix(lang): fix duplicate key.
This commit is contained in:
@@ -1,24 +1,25 @@
|
||||
import { createIntl, createIntlCache } from 'react-intl';
|
||||
import messages from 'lang/en';
|
||||
// import messages from 'lang/en/index.json';
|
||||
import messages from 'lang/ar/index.json';
|
||||
import { setLocale } from 'yup';
|
||||
import {locale} from 'lang/en/locale';
|
||||
|
||||
import { locale } from 'lang/en/locale';
|
||||
|
||||
// This is optional but highly recommended
|
||||
// since it prevents memory leak
|
||||
const cache = createIntlCache()
|
||||
const cache = createIntlCache();
|
||||
|
||||
const intl = createIntl({
|
||||
locale: 'en',
|
||||
messages,
|
||||
}, cache);
|
||||
const intl = createIntl(
|
||||
{
|
||||
locale: 'en',
|
||||
messages,
|
||||
},
|
||||
cache,
|
||||
);
|
||||
|
||||
setLocale(locale)
|
||||
setLocale(locale);
|
||||
|
||||
const { formatMessage } = intl;
|
||||
|
||||
export {
|
||||
formatMessage,
|
||||
};
|
||||
export { formatMessage };
|
||||
|
||||
export default intl;
|
||||
|
||||
Reference in New Issue
Block a user