Deprecate plugin in favor `output.clean`
webpack has built-in support for clearing stale assets https://webpack.js.org/configuration/output/#outputclean, so I think we can deprecate this plugin
I think output.clean does not clean the output directory when running webpack-dev-server, while this plugin seems to be able to.
@galvarez421 it should, what is the problem?
@alexander-akait it seems like output.clean does not clean files for webpack dev server, and you confirmed that it is not supposed to in the issue I logged recently
https://github.com/webpack/webpack/issues/12949
I strongly recommend use the writeToDisk option only for files to be read from fs. otherwise you lose performance
output.clean looks good
but not sure if it supports cleanAfterEveryBuildPatterns?
Why do you need cleanAfterEveryBuildPatterns? Can you describe use case?
Why do you need
cleanAfterEveryBuildPatterns? Can you describe use case?
I'm currently using it to remove intermediate files like sourcemap, after pushed to sentry maybe this is not the best practice, but suit the requirement
/cc @johnagan what do you think? Maybe we need some more options for fully replace this plugin?