A webpack plugin to clean specified files after build. Current stable version is 1.2.5, released sporadically (last update 2020). It deletes specified files (and optionally their .map files) after each webpack build. Differentiators: simple API, optional forceDelete to proceed despite compile errors, and optional removeMaps to auto-delete source maps. Compared to clean-webpack-plugin, it is less maintained but offers direct file specification and force deletion.
npm install webpack-cleanVerified import paths — ran on the pinned version, not inferred.
Basic usage of webpack-clean plugin with multiple files and removeMaps option in webpack config.
Upgrade to a modern alternative like clean-webpack-plugin.
Set forceDelete: true in options to force deletion even on errors.
The fix is included in version 1.2.2+; update to latest.
Upgrade to version 1.2.5.
Update webpack-clean to 1.2.5.
Update to webpack-clean 1.2.2+ or use a different clean plugin.
Ensure webpack-clean 1.2.1+ is installed (winston-color moved to dependencies).