0.1.2 • Published 8 years ago

invalidate-assets-list-webpack-plugin v0.1.2

Weekly downloads
1
License
MIT
Repository
github
Last release
8 years ago

invalidate-assets-list-webpack-plugin

npm version Build Status Test Coverage Dependency Status

Generate (selectively) a list of asset paths to a JSON file for cache invalidation.

Installation

npm i --save-dev invalidate-assets-list-webpack-plugin

Usage

// webpack.config.js
var InvalidateAssetsListPlugin = require('invalidate-assets-list-webpack-plugin');

module.exports = {
  // ...
  plugins: [
    new InvalidateAssetsListPlugin()
  ],
  // ...
};

Options

new InvalidateAssetsListPlugin(options)

options.filename

Exported JSON filename.

  • Default: invalidate-assets.json

options.hash

Appends hash as a query string to files that do not contain them: (e.g. helloWorld.js to helloWorld.js?1455678)

  • Default: false

options.ignore

List of glob patterns to ignore. Can be a String or an Array of Strings.

options.matchOptions

Options object for options.ignore glob patterns.

  • Default: { dot: true, matchBase: true }
  • Accepts options from minimatch

options.path

Path of the exported JSON.

  • Default: ''