{"library":"remove-files-webpack-plugin","title":"remove-files-webpack-plugin","description":"A webpack plugin for removing files and folders before and after compilation. Current stable version is 1.5.0, released 2021-04-12. Supports webpack >= 2.2.0 and Node >= 8.3.0. Ships TypeScript types. Key differentiators: supports before, after, and watch compilation modes; handles symbolic links as ordinary files; works on all OS with platform-specific path handling. Unlike clean-webpack-plugin, it allows granular control over which files to remove and supports watch mode cleanup. Development appears dormant since 2021.","language":"javascript","status":"maintenance","last_verified":"Sat Apr 25","install":{"commands":["npm install remove-files-webpack-plugin"],"cli":null},"imports":["const RemovePlugin = require('remove-files-webpack-plugin');","import RemovePlugin = require('remove-files-webpack-plugin');","new RemovePlugin({ before: { include: ['dist'] } })"],"auth":{"required":false,"env_vars":[]},"quickstart":{"code":"const RemovePlugin = require('remove-files-webpack-plugin');\n\nmodule.exports = {\n  context: __dirname,\n  entry: './src/index.js',\n  output: { path: './dist', filename: 'bundle.js' },\n  plugins: [\n    new RemovePlugin({\n      before: {\n        include: ['./dist'],\n        allowRoot: false\n      },\n      after: {\n        include: ['./dist/temp']\n      }\n    })\n  ]\n};","lang":"javascript","description":"Demonstrates removing the 'dist' folder before compilation and a 'temp' folder after compilation using the before and after namespaces.","tag":null,"tag_description":null,"last_tested":null,"results":[]},"compatibility":null}