You are running the esm-bundler build of vue-i18n. It is recommended to configure your bundler to explicitly replace feature flag globals with boolean literals to get proper tree-shaking in the final bundle.

使用vue-i18n插件时,控制台输出上边的警告,改下引用方式

import { createI18n } from 'vue-i18n';     // 修改前
import { createI18n } from 'vue-i18n/index';     // 修改后
Logo

为开发者提供学习成长、分享交流、生态实践、资源工具等服务,帮助开发者快速成长。

更多推荐