vue运行报错TypeError: Cannot read property ‘parseComponent‘ of undefined

it2025-12-30  6

运行

npm install --dev @vue/component-compiler-utils@1.3.1

参考原文大佬链接

结果它继续报错应该是每个人情况不同,不要慌我们继续

我这里报错,如图:

下边他给了错误提示

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.

如果使用的是vue loader@>=10.0,只需更新vue模板编译器。 如果使用的是vue loader@<10.0或vueify,则重新安装vue loader/vueify应将vue模板编译器升级到最新版本。

参考原文链接

npm i vue-template-compiler@2.6.11 --save (这里的@2.6.11根据自己报错vue的版本)
最新回复(0)