webpack-bundle-diff-add-children
TypeScript icon, indicating that this package has built-in type declarations

0.1.0 • Public • Published

webpack-bundle-diff-add-children

npm, github

A utility to add children to the bundle graph produced by webpack-bundle-diff (npm, github)

Usage

yarn add webpack-bundle-diff-add-children

const getModuleGraphWithChildren = require('webpack-bundle-diff-add-children')
    .getModuleGraphWithChildren
const deriveBundleData = require('webpack-bundle-diff').deriveBundleData

// Get your bundle stats somehow
const webpackStats = require('fs').readFileSync('./stats.json', 'utf-8')

// Derive webpack-bundle-diff data
const data = deriveBundleData(webpackStats)

// Add children to the graph
const graphWithChildren = getModuleGraphWithChildren(stats.bundleData.graph)

Development

yarn # install dependencies
yarn build # build.             Can also use `rollup -c`
yarn watch # build with watch.  Can also use `rollup -cw`

Dependents (0)

Package Sidebar

Install

npm i webpack-bundle-diff-add-children

Weekly Downloads

0

Version

0.1.0

License

MIT

Unpacked Size

169 kB

Total Files

10

Last publish

Collaborators

  • adjective