razzle-plugin-bundle-analyzer

4.2.18 • Public • Published

razzle-plugin-bundle-analyzer

This package contains a plugin for using webpack-bundle-analyzer with Razzle

Usage in Razzle Projects

yarn add razzle-plugin-bundle-analyzer

Using the plugin with the default options

// razzle.config.js

module.exports = {
  plugins: ['bundle-analyzer'],
};

With custom options:

// razzle.config.js

module.exports = {
  plugins: [
    {
      name: 'bundle-analyzer',
      options: {
        target: 'web', // or 'node'
        env: 'production', // or 'development'
        bundleAnalyzerConfig: {},
      },
    },
  ],
};

Options

target: string (defaults: 'web')

env: string (defaults: 'production')

bundleAnalyzerConfig: bundleAnalyzerOptions (defaults: {})

Use this to override webpack-bundle-analyzer options. Check all the options here: webpack-bundle-analyzer options.

Readme

Keywords

none

Package Sidebar

Install

npm i razzle-plugin-bundle-analyzer

Weekly Downloads

2,432

Version

4.2.18

License

MIT

Unpacked Size

7.75 kB

Total Files

5

Last publish

Collaborators

  • jaredpalmer
  • nima_arf
  • razzle-bot