解决vue和vue-template-compiler版本不一样的快捷办法
vue项目,package.json中Vue和vue-template-compiler版本不一致时,执行npm run dev有时会报错提示如下内容in ./src/views/login/index.vueModule build failed: Error:Vue packages version mismatch:- vue@2.5.10 (E:\美好家\beauty_w...
·
vue项目,package.json中Vue和vue-template-compiler版本不一致时,执行npm run dev有时会报错
提示如下内容
in ./src/views/login/index.vue
Module build failed: Error:
Vue packages version mismatch:
- vue@2.5.10 (E:\美好家\beauty_web\move\node_modules\vue\dist\vue.runtime.common.js)
- vue-template-compiler@2.6.10 (E:\美好家\beauty_web\move\node_modules\vue-template-compiler\package.json)
This may cause things to work incorrectly. Make sure to use the same version for both.
If you are using vue-loader@>=10.0, simply update vue-template-compiler.
If you are using vue-loader@<10.0 or vueify, re-installing vue-loader/vueify should bump vue-template-compiler to the latest.
解决方法 :
第一步:执行npm uninstall vue-template-compiler
第二步:执行npm install vue-template-compiler@报错中提示的vue的版本号
报错中提示的vue的版本号 一般指的使
所以以本次错误测试案例执行的方法为如下内容
第一步:执行npm uninstall vue-template-compiler
第二步:执行npm install vue-template-compiler@2.5.10
如果帮助到了你请帮忙点个赞
更多推荐
已为社区贡献7条内容
所有评论(0)