minifier
minifier copied to clipboard
0.8.0; issue with arrow functions?
If I try to minify a script including an arrow function like this:
Object.keys(obj).forEach(key => { data[obj[key].name] = obj[key].value; });
I get an
undefined:1553 throw new JS_Parse_Error(message, filename, line, col, pos); ^ Error (etc)
If I minify the same file but change the arrow function back to a regular function
Object.keys(obj).forEach(function(key) { data[obj[key].name] = obj[key].value; });
all works fine.
This is a duplicate of #19, in that the version of uglifyjs used only supports ES5 syntax