minor
This commit is contained in:
@@ -11,27 +11,28 @@ var code = fs.readFileSync(filename, "utf8");
|
||||
var ast = time_it("parse", function() {
|
||||
return UglifyJS.parse(code);
|
||||
});
|
||||
var stream = UglifyJS.OutputStream({ beautify: true });
|
||||
var stream = UglifyJS.OutputStream({ beautify: false });
|
||||
time_it("scope", function(){
|
||||
ast.figure_out_scope();
|
||||
});
|
||||
time_it("mangle", function(){
|
||||
ast.mangle_names();
|
||||
});
|
||||
// time_it("mangle", function(){
|
||||
// ast.mangle_names();
|
||||
// });
|
||||
|
||||
ast.scope_warnings();
|
||||
//ast.scope_warnings();
|
||||
|
||||
time_it("compress", function(){
|
||||
var compressor = new UglifyJS.Compressor({
|
||||
});
|
||||
ast = ast.squeeze(compressor);
|
||||
});
|
||||
|
||||
time_it("generate", function(){
|
||||
ast.print(stream);
|
||||
});
|
||||
sys.puts(stream.get());
|
||||
|
||||
ast.scope_warnings();
|
||||
//ast.scope_warnings();
|
||||
|
||||
function time_it(name, cont) {
|
||||
var t1 = new Date().getTime();
|
||||
|
||||
Reference in New Issue
Block a user