gdborton / webpack-parallel-uglify-plugin

A faster uglifyjs plugin.
466 stars 34 forks source link

How does this compare to uglifyjs-webpack-plugin? #46

Closed mnpenner closed 4 years ago

mnpenner commented 6 years ago

uglifyjs-webpack-plugin now supports a parallel option. Does that make these two plugins more-or-less the same, or is one faster than the other?

gdborton commented 6 years ago

I haven't run any bench marks against the built in plugin, but a few people have reported that it's minimally faster. Either should be "fast enough™".

That being said it automatically places you onto uglify-es, which is in a semi-unmaintained state AFAIK - https://github.com/webpack-contrib/uglifyjs-webpack-plugin/issues/262

Ignoring that, this plugin allows for either UglifyJS or UglifyES depending on the options that you provide. At Airbnb, we're relying on this behavior to prevent unintentionally shipping es6 code that sometimes sneaks into our node_modules/, as UglifyJS will fail to parse.