empty-webpack-build-detail-plugin

1.1.3 • Public • Published

empty-webpack-build-detail-plugin

friendly display compilation details

Install

  cnpm install empty-webpack-build-detail-plugin -D
  npm i empty-webpack-build-detail-plugin -D
  yarn add --dev empty-webpack-build-detail-plugin

This is a webpack plugin tailored for emptyd-desgin and can be used in your project. No difference

Zero Config

The empty-webpack-build-detail-plugin works without configuration.

Usage

The plugin will friendly display compilation details

webpack.config.prod.js

const emptyWebpackBuildDetailPlugin = require("empty-webpack-build-detail-plugin");

module.exports = {
    -entry: 'index.js',
    -output: {
        -path: __dirname + '/dist',
        -filename: 'index_bundle.js'
    -},
    plugins: [
        new emptyWebpackBuildDetailPlugin(options)
    ]
}

Options

You can pass a hash of configuration options to empty-webpack-build-detail-plugin. Allowed values are as follows

Name Type Default Description
path {String} compilation.options.context The path to use for the compile log
filename {String} 'compilation-detail.md' The file to write the compile log to. Defaults to compilation-detail.md
warnAfterBundleGzipSize {number} 512*1024 (Bit) Maximum limit for bundle files
warnAfterChunkGzipSize {number} 1024*1024 (Bit) Maximum limit for chunk files

Here's an example webpack config illustrating how to use these options

webpack.config.js

{
  entry: 'index.js',
  output: {
    path: __dirname + '/dist',
    filename: 'index_bundle.js'
  },
  plugins: [
    new emptyWebpackBuildDetailPlugin({
      path: path.join(process.cwd(),'log'),
      filename: 'compile-log.md'
    })
  ]
}

Maintainers

freemenL

Readme

Keywords

none

Package Sidebar

Install

npm i empty-webpack-build-detail-plugin

Weekly Downloads

2

Version

1.1.3

License

ISC

Unpacked Size

9.92 kB

Total Files

3

Last publish

Collaborators

  • fremenl