remove-webpack-plugin
v1.2.2
Published
Plugin for webpack to remove directorys or files.
Downloads
685
Maintainers
Readme
Remove Webpack Plugin
Plugin for webpack to remove directorys or files. (rm -r
)
Installation
Install the plugin with npm:
npm install remove-webpack-plugin --save-dev
Examples Webpack Config
var RemoveWebpackPlugin = require('remove-webpack-plugin');
module.exports = {
plugins: [
new RemoveWebpackPlugin('./public/')
]
}
var RemoveWebpackPlugin = require('remove-webpack-plugin');
module.exports = {
plugins: [
new RemoveWebpackPlugin(['./public/', './build/'], )
]
}
var RemoveWebpackPlugin = require('remove-webpack-plugin');
module.exports = {
plugins: [
new RemoveWebpackPlugin(['./public/', './build/'], 'show')
]
}
var RemoveWebpackPlugin = require('remove-webpack-plugin');
module.exports = {
plugins: [
new RemoveWebpackPlugin(['./public/', './build/'], 'hide')
]
}
var RemoveWebpackPlugin = require('remove-webpack-plugin');
module.exports = {
plugins: [
new RemoveWebpackPlugin(['./public/', './build/'], 'fatal')
]
}
var RemoveWebpackPlugin = require('remove-webpack-plugin');
module.exports = {
plugins: [
new RemoveWebpackPlugin(['./public/', './build/'], {
errors: 'hide'
})
]
}
var RemoveWebpackPlugin = require('remove-webpack-plugin');
module.exports = {
plugins: [
new RemoveWebpackPlugin(['./public/', './build/'], {
errors: 'show'
})
]
}
var RemoveWebpackPlugin = require('remove-webpack-plugin');
module.exports = {
plugins: [
new RemoveWebpackPlugin(['./public/', './build/'], {
errors: 'fatal'
})
]
}
Usage
new RemoveWebpackPlugin(paths, ?settings)
Params
- paths: Array || String
- errors/settings: String("show" || "hide" || 'fatal')/Object{ errors: "show" || "hide" || "fatal"} default: "show"
License
MIT