Uncaught ReferenceError: __DEV__ is not defined
kunzhu0710 opened this issue · comments
kunzhu0710 commented
打开页面报这个错,页面一片空白
Uncaught ReferenceError: DEV is not defined
at Function.RootClass.extend (clazz.js?00f5:66)
at eval (Component.js?bbb1:23)
at Object. (app.js:895)
at webpack_require (app.js:689)
at fn (app.js:110)
at eval (Global.js?6f94:1)
at Object. (app.js:4998)
at webpack_require (app.js:689)
at fn (app.js:110)
at Object.eval (echarts.js?4ad2:1)
Deleted user commented
npm run build 打包项目后,再运行 npm run dev 就报同上错误
luoxy1001 commented
@kunzhu0710 我的也报错了,这好像是echart版本更新的错,在webpack配置变量就可以了
new webpack.DefinePlugin({
__DEV__: false,
'process.env': config.dev.env
})
Deleted user commented
@luoxy1001 我一会试一下,谢谢你蛤
wangxdmm commented
我也是这样配置的 但是不知道为什么报错,只能定义一个变量 DEV