为什么配置了vue.config.js之后 npm run build 报错了
来源:2-8 vue-cli 3.0搭建方法(脚手架创建项目)

糍粑鱼
2019-11-19
ERROR Invalid options in vue.config.js: “baseUrl” is not allowed
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! vue-imooc-ebook@0.1.0 build: vue-cli-service build
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the vue-imooc-ebook@0.1.0 build script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.
npm ERR! A complete log of this run can be found in:
npm ERR! C:\Users\Administrator\AppData\Roaming\npm-cache_logs\2019-11-19T14_40_08_691Z-debug.log
写回答
1回答
-
糍粑鱼
提问者
2019-11-19
自己找到原因了 提示'baseUrl' is not allowed
要用publicPath 这真是一个坑
122022-09-03
相似问题