🚨 Shai-Hulud Strikes Again:834 Packages Compromised.Technical Analysis →
Socket
Book a DemoInstallSign in
Socket

@grapes-agency/named-chunk-group

Package Overview
Dependencies
Maintainers
2
Versions
3
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@grapes-agency/named-chunk-group

A webpack plugin to generate a manifest.json grouped by chunk names.

latest
npmnpm
Version
1.0.2
Version published
Weekly downloads
0
Maintainers
2
Weekly downloads
 
Created
Source

named-chunk-group

A webpack plugin to generate a manifest.json grouped by chunk names.

Install

$ npm install --save-dev @grapes-agency/named-chunk-group

Usage

const NamedChunkGroupPlugin = require("@grapes-agency/named-chunk-group");
const path = require("path");

const webpackConfig = {
  entry: {
    main: "main.js",
    polyfill: "polyfill.js"
  },
  output: {
    filename: "[name].js",
    chunkFilename: "[name].js",
    path: path.resolve(__dirname, "dist")
  },
  plugins: [
    new NamedChunkGroupPlugin({
      filename: "./manifest.json"
    })
  ]
};

This will generate a manifest.json with this content:

{
  "main": [
    {
      "id": "main",
      "name": "main",
      "file": "main.js",
      "publicPath": "/dist/main.js"
    }
  ],
  "polyfill": [
    {
      "id": "polyfill",
      "name": "polyfill",
      "file": "polyfill.js",
      "publicPath": "/dist/polyfill.js"
    }
  ]
}

Keywords

webpack

FAQs

Package last updated on 08 Jan 2019

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