一、报错信息
Uncaught TypeError: Cannot assign to read only property ‘exports’ of object ‘#’
at Module.eval (BaseClient.js:12:1)
at eval (BaseClient.js:40:30)
at ./node_modules/webpack-dev-server/client/clients/BaseClient.js (app.js:4382:1)
at webpack_require (app.js:790:30)
at fn (app.js:101:20)
at Module.eval (SockJSClient.js:30:1)
at eval (SockJSClient.js:160:30)
at ./node_modules/webpack-dev-server/client/clients/SockJSClient.js (app.js:4394:1)
at webpack_require (app.js:790:30)】
二、解决办法
注释掉 “transform-runtime”
{
"presets": [
[
"env",
{
"modules": false,
"targets": {
"browsers": [
"> 1%",
"last 2 versions",
"not ie <= 8"
]
}
}
],
"stage-2"
],
"plugins": [
"transform-vue-jsx",
// "transform-runtime"
]
}