toplevel shorthand for ecma (#2157)

This commit is contained in:
Alex Lam S.L
2017-06-24 19:06:58 +08:00
committed by GitHub
parent 94f93ad82d
commit 49f3de8397
3 changed files with 8 additions and 0 deletions

View File

@@ -32,6 +32,7 @@ function minify(files, options) {
try {
options = defaults(options, {
compress: {},
ecma: undefined,
ie8: false,
keep_fnames: false,
mangle: {},
@@ -46,6 +47,7 @@ function minify(files, options) {
var timings = options.timings && {
start: Date.now()
};
set_shorthand("ecma", options, [ "parse", "compress", "output" ]);
set_shorthand("ie8", options, [ "compress", "mangle", "output" ]);
set_shorthand("keep_fnames", options, [ "compress", "mangle" ]);
set_shorthand("toplevel", options, [ "compress", "mangle" ]);