esshorten
esshorten copied to clipboard
Shorten (mangle) names in JavaScript code
Node11 and Node8 sort results are different when return 0 by `Array.sort`. This causes the generated variable names to be inconsistent in different versions. For background: https://v8.dev/blog/array-sort (from @mathiasbynens )
In my setup `mangle` at somepoint generated similar code: ``` javascript var a = function () {...}; try { ... } catch (a) { ... } return a(); ``` It...
This bug was introduced by our PR #18. It was causing the namePrefix to be added multiple times to renamed variables in some scenarios (ie: IIFE). Here is an example...