原因1:vue与vue-tempalte-compiler的版本不一致
解决方案:重新安装vue-tempalte-compiler,或者忽略,此问题只是出现在本地环境,发布之后,此问题不复存在。
- 卸载vue-template-compiler npm uninstall vue-template-compiler
- 安装 npm install vue-template-compiler @报错中提示的版本
原因2:重复引入 new vue()(可能在main.js页面和index.html页面重复引入)
解决方案:移除多余的引入