fix: i18n bug in production

This commit is contained in:
xiaoxian521
2021-05-07 23:17:15 +08:00
parent 7ed66b321d
commit f0e780c48f
3 changed files with 8 additions and 5 deletions

View File

@@ -62,6 +62,10 @@ const components = [
const plugins = [ElLoading];
import ElementLocale from "element-plus/lib/locale";
import zhLocale from "element-plus/lib/locale/lang/zh-cn";
ElementLocale.use(zhLocale);
export function useElementPlus(app: App) {
components.forEach((component) => {
app.component(component.name, component);

View File

@@ -4,10 +4,8 @@ import zhVxeTable from "vxe-table/lib/locale/lang/zh-CN";
import enVxeTable from "vxe-table/lib/locale/lang/en-US";
// element-plus国际化
import { locale } from "element-plus";
import enLocale from "element-plus/lib/locale/lang/en";
import zhLocale from "element-plus/lib/locale/lang/zh-cn";
locale(zhLocale);
export const menusConfig = {
zh: {