webpack-md5-manifest-plugin

1.1.0 • Public • Published

webpack-md5-manifest-plugin

Generate JSON manifest based on the MD5 of files.

Build Status npm package

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.

Package Sidebar

Install

npm i webpack-md5-manifest-plugin

Weekly Downloads

2

Version

1.1.0

License

MIT

Last publish

Collaborators

  • sdvcrx