webpack-md5-manifest-plugin
v1.1.0
Published
Generate JSON manifest based on the MD5 of files
Downloads
4
Maintainers
Readme
webpack-md5-manifest-plugin
Generate JSON manifest based on the MD5 of files.
Usage
In your webpack.config.js
:
const MD5Plugin = require('webpack-md5-manifest-plugin');
module.exports = {
// ...
plugins: [
// ...
new MD5Plugin()
]
}
Output example:
// dist/manifest.json
{
"app.bundle.js": "20036d7b35b3613aa3c3baf24accc285",
"lib.bundle.js": "e92ac4fed9a627c489ffeda66b9f4721"
}
Options
// webpack.config.js
module.exports = {
output: {
path: path.resolve(__dirname, 'dist')
},
plugins: [
new MD5Plugin(options)
]
}
options.name
Type: String
Default: manifest.json
The output manifest filename.
options.algorithm
Type: String
Default: md5
The hash algorithm.