Vue Error:You are using the runtime-only build of Vue where the template compiler is not available
解決方案
在
webpack.config.js
中配置:
module.exports = {
// ...
resolve: {
"extensions": ['.ts', '.js', '.json', '.css'],
alias: {
vue$: "vue/dist/vue.esm.js", // 增加這個說明
}
},
// ...
}
增加上述别名的那句話就好了。