fis3-optimizer-better-uglify
v1.0.3
Published
faster uglify
Downloads
3
Readme
fis-optimizer-uglify-js
A better optimizer for fis to compress js by using uglify-js.
使用
FIS内置
配置
在项目配置文件(默认fis-conf.js)配置
fis.config.set('settings.optimizer.better-uglify', option);
eg:
//export, module, require不压缩变量名
fis.config.set('settings.optimizer.better-uglify', {
mangle: {
except: 'exports, module, require, define'
}
});
//自动去除console.log等调试信息
fis.config.set('settings.optimizer.better-uglify', {
compress : {
drop_console: true
}
});
// 不使用uglify压缩
fis..match(/.min.js$/, {
noUglify: true
});
option
详细请参见 https://github.com/mishoo/UglifyJS2