add i18n
This commit is contained in:
1 parent
59728e46b3
commit
69fdb3a933
6 files changed
+126
-4
No files matched your search
@@ -0,0 +1,22 @@
|
||||
import enLang from './en/index';
|
||||
import zhLang from './zh/index';
|
||||
import enLocale from 'element-plus/lib/locale/lang/en';
|
||||
import zhLocale from 'element-plus/lib/locale/lang/zh-cn';
|
||||
import { createI18n } from 'vue-i18n';
|
||||
|
||||
const i18n = createI18n({
|
||||
locale: zhLocale.name,
|
||||
fallbackLocale: enLocale.name,
|
||||
messages: {
|
||||
[enLocale.name]: {
|
||||
el: enLocale.el,
|
||||
...enLang
|
||||
},
|
||||
[zhLocale.name]: {
|
||||
el: zhLocale.el,
|
||||
...zhLang
|
||||
}
|
||||
}
|
||||
});
|
||||
|
||||
export default i18n;
|
||||
Reference in new issue
Block a user