-
Notifications
You must be signed in to change notification settings - Fork 136
Plugin has unexpected effects if not added first #150
Copy link
Copy link
Open
Description
Issue description
workbox-webpack-plugin has an option to add a versioned workbox folder to the output directory.
When clean-webpack-plugin v3 is in the plugins list before workbox-webpack-plugin everything works as expected, but when it's in the plugins list after workbox-webpack-plugin the versioned workbox folder is missing.
With clean-webpack-plugin v2 the workbox folder is always present.
Webpack Config
const { CleanWebpackPlugin } = require("clean-webpack-plugin");
const WorkboxWebpackPlugin = require("workbox-webpack-plugin");
module.exports = {
mode: "production",
plugins: [
new CleanWebpackPlugin(), // workbox directory is present
new WorkboxWebpackPlugin.GenerateSW({
importWorkboxFrom: "local"
})
// new CleanWebpackPlugin() // workbox directory is missing
]
};Environment
clean-webpack-plugin: ^3.0.0 => 3.0.0
webpack: ^4.35.0 => 4.35.0
workbox-webpack-plugin: ^4.3.1 => 4.3.1
Repository to reproduce the issue: https://github.com/hubgit/clean-workbox-example
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels