版权属于:
Ginkgo
本文链接:
https://www.imao2.com/article/104.html(转载时请注明本文出处及文章链接)
作品采用:
1、在打包过程中过程中出现如下问题 use of eval
is strongly discouraged
解决方案:
添加 replace 插件,并进行插件配置
// rollup.config.js
import nodeResolve from 'rollup-plugin-node-resolve';
import commonjs from 'rollup-plugin-commonjs';
import replace from 'rollup-plugin-replace';
// ...etc
export default {
// ...other config...
plugins: [
nodeResolve({...}),
commonjs({...}),
replace({
include: 'node_modules/firebase/firebase.js',
values: {
'eval(' : '[eval][0]('
}
})
]
};