A webpack plugin that runs UglifyJS (or Terser) in parallel across multiple workers to speed up minification of bundled assets. Version 2.0.0 is the current stable release, but the project appears to be in maintenance mode with no recent updates (last release 2019). It leverages Node.js worker threads to distribute minification of each output file across available CPU cores, offering significant build time reductions for projects with many entry points. Compared to built-in webpack UglifyJS plugin, it can reduce minification time from minutes to seconds. Supports both UglifyJS (ES5) and Terser (ES6+), along with caching, file inclusion/exclusion by pattern, and source maps. Requires webpack as a peer dependency.
npm install webpack-parallel-uglify-pluginVerified import paths — ran on the pinned version, not inferred.
Shows how to configure the plugin with UglifyJS options, caching, and worker count.
Replace with 'terser-webpack-plugin' and update configuration accordingly.
Choose only one minifier: either UglifyJS or Terser.
Set terser options instead of uglifyJS if your code uses ES6+.
Run 'npm install webpack-parallel-uglify-plugin --save-dev' and ensure correct import statement.
Use 'const ParallelUglifyPlugin = require('webpack-parallel-uglify-plugin').default;'Remove one of the options: either uglifyJS or terser.