mirror of
https://github.com/bigcapitalhq/bigcapital.git
synced 2026-02-18 05:40:31 +00:00
feat: optimize sale estimate form performance.
feat: optimize sale receipt form performance. feat: optimize sale invoice form performance. feat: optimize bill form performance.
This commit is contained in:
24
client/src/services/intl.js
Normal file
24
client/src/services/intl.js
Normal file
@@ -0,0 +1,24 @@
|
||||
import { createIntl, createIntlCache } from 'react-intl';
|
||||
import messages from 'lang/en';
|
||||
import { setLocale } from 'yup';
|
||||
import {locale} from 'lang/en/locale';
|
||||
|
||||
|
||||
// This is optional but highly recommended
|
||||
// since it prevents memory leak
|
||||
const cache = createIntlCache()
|
||||
|
||||
const intl = createIntl({
|
||||
locale: 'en',
|
||||
messages,
|
||||
}, cache);
|
||||
|
||||
setLocale(locale)
|
||||
|
||||
const { formatMessage } = intl;
|
||||
|
||||
export {
|
||||
formatMessage,
|
||||
};
|
||||
|
||||
export default intl;
|
||||
Reference in New Issue
Block a user