How to use inspectpack - 2 common examples

To help you get started, we’ve selected a few inspectpack examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github mrin9 / RapiDoc / webpack.config.js View on Github external
new HtmlWebpackPlugin({ template: 'index.html' }),
  new CompressionPlugin(),
  new FileManagerPlugin({
    onEnd: {
      copy: [
        { source: 'dist/*.js', destination: 'docs' },
        { source: 'dist/*.woff2', destination: 'docs' },
      ],
    },
  }),
];

if (process.env.NODE_ENV === 'production') {
  console.log('BUILDING FOR PRODUCTION ... '); // eslint-disable-line no-console
  commonPlugins.push(new BundleAnalyzerPlugin({ analyzerMode: 'static' }));
  commonPlugins.push(new DuplicatesPlugin({ emitErrors: false, verbose: true }));
}

module.exports = {
  entry: './src/index.js',
  node: { fs: 'empty' },
  externals: {
    esprima: 'esprima',
    'native-promise-only': 'native-promise-only',
    commander: 'commander',
    yargs: 'yargs',
  },
  optimization: {
    splitChunks: {
      chunks: 'all',
    },
  },
github mrin9 / RapiPdf / webpack.config.js View on Github external
new HtmlWebpackPlugin({template: 'index.html'}),
  new CleanWebpackPlugin(),
  new CompressionPlugin(),
  new FileManagerPlugin({
    onEnd: {
      copy: [
        { source: 'dist/*.js', destination: 'docs' },
      ],
    },
  }),
];

if (process.env.NODE_ENV === 'production') {
  console.log('BUILDING FOR PRODUCTION ... ');
  commonPlugins.push(new BundleAnalyzerPlugin({ analyzerMode:'static' }));
  commonPlugins.push(new DuplicatesPlugin({ emitErrors: false, verbose: true }));
}


module.exports = {
  entry: './src/index.js',
  node: { fs: 'empty' },
  externals: {
    esprima: 'esprima',
    commander: 'commander',
    'native-promise-only':'native-promise-only',
    yargs: 'yargs',
  },
  optimization: {
    splitChunks: {
      chunks: 'all',
    },

inspectpack

An inspection tool for Webpack frontend JavaScript bundles.

MIT
Latest version published 4 years ago

Package Health Score

59 / 100
Full package analysis

Popular inspectpack functions