Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

chunk-manifest-webpack2-plugin

Package Overview
Dependencies
Maintainers
1
Versions
2
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

chunk-manifest-webpack2-plugin

Allows exporting a manifest that maps chunk ids to their output files, instead of keeping the mapping inside the webpack2 bootstrap.

  • 1.0.1
  • latest
  • Source
  • npm
  • Socket score

Version published
Maintainers
1
Created
Source

chunk-manifest-webpack2-plugin

Allows exporting a JSON file that maps chunk ids to their resulting asset files. Webpack can then read this mapping, assuming it is provided somehow on the client, instead of storing a mapping (with chunk asset hashes) in the bootstrap script, which allows to actually leverage long-term caching.

Example

https://webpack.js.org/how-to/cache/ and https://medium.com/@okonetchnikov/long-term-caching-of-static-assets-with-webpack-1ecb139adb95#.jg0szik07

Usage

Install via npm:

npm install chunk-manifest-webpack2-plugin

And then require and provide to webpack:

// in webpack.config.js or similar
var ChunkManifestPlugin = require('chunk-manifest-webpack2-plugin');

module.exports = {
  // your config values here
  plugins: [
    new ChunkManifestPlugin({
      filename: "manifest.json",
      manifestVariable: "webpackManifest"
    })
  ]
};

Options

filename

Where the manifest will be exported to on bundle compilation. This will be relative to the main webpack output directory. Default = "manifest.json"

manifestVariable

What JS variable on the client webpack should refer to when requiring chunks. Default = "webpackManifest"

Keywords

FAQs

Package last updated on 25 Oct 2016

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc