(//)( )console.log\(.*\);+ 利用 VSCode 或 WebStorm 这类编辑器的正则替换功能可以很轻松的替换。 利用 babel 插件 在 nuxt 中配置如下: export default { build: { babel: { babelrc: false, cacheDire ...
修改 nuxt.config.js /* ** Build configuration */ build: { /* 如果node_modules中使用了ES6导致浏览器报错,使用transpile告知babel需要编译 */ transpile: [/has-values|ramda/], babel: { babelrc: fa ...