jardenliu / wepy-plugin-iview

A wepy plugin for weapp-iview
29 stars 8 forks source link

uglifyjs压缩js后, json文件里的usingComponents没有生成 #11

Closed billyshen26 closed 5 years ago

billyshen26 commented 5 years ago
"wepy-plugin-iview": "^1.2.0-rc.2",
"wepy-plugin-uglifyjs": "^1.3.7"

当我使用uglifyjs压缩js后, 生成的dist文件夹中的page里面的json文件没有usingComponents,到时组件无法使用。以下是uglifyjs配置 // 压缩js module.exports.plugins = { uglifyjs: { filter: /.js$/, config: { } } }

请问如何解决

jardenliu commented 5 years ago

你的plugin被覆盖了啊

billyshen26 commented 5 years ago

不好意思,确实被覆盖了,多谢指点

encorehe commented 5 years ago

你好 我也碰到这个问题 该如何配置呢?🙏

jardenliu commented 5 years ago

if (prod)里面改

encorehe commented 5 years ago

怎么改啊 ,找半天了 ,帮忙指教一下呗,🙏

jardenliu commented 5 years ago

@encorehe module.exports.plugins ={...} 这里看不出来问题吗?