Vue---报错You are using the runtime-only build of Vue where the template compiler is not available

报错信息:

[Vue warn]: You are using the runtime-only build of Vue where the template compiler is not available. Either pre-compile the templates into render functions, or use the compiler-included build.

翻译后的意思是:在模板编译器不可用的情况下,您使用的是仅运行时版本的Vue。可以将模板预编译为呈现函数,也可以使用编译器包含的内部版本。

解决:

Vue项目配置文件加入配置:runtimeCompiler : true

猜你喜欢

转载自blog.csdn.net/qq_39115469/article/details/112002237