appcache-webpack-plugin

by lettertwo

Generate an HTML5 Application Cache for a Webpack build

201 Stars 32 Forks Last release: Not found 55 Commits 9 Releases

Available items

No Items, yet!

The developer of this repository has not created any items for sale yet. Need a bug fixed? Help with integration? A different license? Create a request here:

Application Cache plugin for Webpack

Usage

var AppCachePlugin = require('appcache-webpack-plugin');

module.exports = { plugins: [ new AppCachePlugin({ cache: ['someOtherAsset.jpg'], network: null, // No network access allowed! fallback: ['failwhale.jpg'], settings: ['prefer-online'], exclude: ['file.txt', /.*.js$/], // Exclude file.txt and all .js files output: 'my-manifest.appcache' }) ] }

Arguments:

  • cache
    : An array of additional assets to cache.
  • network
    : An array of assets that may be accessed via the network. Defaults to
    ['*']
    .
  • fallback
    : An array of fallback assets.
  • settings
    : An array of settings.
  • exclude
    : An array of strings or regex patterns. Assets in the compilation that match any of these patterns will be excluded from the manifest.
  • output
    : The filename to write the appcache to

License

MIT

We use cookies. If you continue to browse the site, you agree to the use of cookies. For more information on our use of cookies please see our Privacy Policy.