noahlam / Miment

a fast,light weight,simple and non-dependencies datetime library for javascript ( mini moment )

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

项目中若使用UglifyJs在一起会报错

Licoy opened this issue · comments

问题过程

最终发现去除minment即可

还望作者查看是何原因导致的

commented

new webpack.optimize.UglifyJsPlugin({
compress: {
warnings: false
}
}),

我试了用这个打包,没发现问题

commented

我看了一下你的webpack配置,发现还有一个
new HtmlWebpackPlugin({
title: 'Watch Dog' + package.version,
favicon: './ico.png',
filename: '../index.html',
template: '!!ejs-loader!./src/template/index.ejs',
inject: false
})
如果是ejs的话,应该是属于浏览器环境,要使用浏览器版本的.

原来是这样啊,谢谢作者