解决 Cannot assign to read only property 'exports' of object '#' 问题

如果是 babel6,可以尝试使用:

 

https://www.npmjs.com/package/babel-plugin-transform-es2015-modules-commonjs

 

先安装:

npm install --save-dev babel-plugin-transform-es2015-modules-commonjs

 

然后再 .babelrc 中添加该插件

 "plugins": ["transform-es2015-modules-commonjs"]

 


免责声明!

本站转载的文章为个人学习借鉴使用,本站对版权不负任何法律责任。如果侵犯了您的隐私权益,请联系本站邮箱yoyou2525@163.com删除。



猜您在找 Cannot assign to read only property 'exports' of object 解决办法 Cannot assign to read only property 'exports' of object '#' Cannot assign to read only property 'exports' of object '#' Uncaught TypeError: Cannot assign to read only property 'exports' of object '#' Cannot assign to read only property 'exports' of object '#' ,文件名大小写问题!!! 关于vue-cli3打包时遇到Cannot assign to read only property 'exports' of object '#'问题的解决方法。 Vue报错:Uncaught TypeError: Cannot assign to read only property’exports‘ of object’#‘的解决方法 Vue报错:Uncaught TypeError: Cannot assign to read only property 'exports' of object 的解决方法 Vue的报错:Uncaught TypeError: Cannot assign to read only property 'exports' of object '#' vue 项目启动报错:Cannot assign to read only property 'exports' of object '#'
 
粤ICP备18138465号  © 2018-2025 CODEPRJ.COM