1.1.27 • Published 7 years ago

webpack-css-treeshaking-plugin v1.1.27

Weekly downloads
12
License
MIT
Repository
github
Last release
7 years ago

webpack-css-treeshaking-plugin

a webpack plugin to shake unused css code


how to use

npm install webpack-css-treeshaking-plugin -D

config it in your webpack configuration file, it depends on extracting styles to a file, so please use ExtractTextPlugin first.

var ExtractTextPlugin = require('extract-text-webpack-plugin')
const CssTreeShakingPlugin = require("webpack-css-treeshaking-plugin")

module.exports = {
  plugins: [
    new CssTreeShakingPlugin({
      remove: false,
      ignore: ['state-\d']
    }),
    new ExtractTextPlugin({
      filename: 'build/style.css'
    })
  ]
};

configuration

  • remove, boolean remove unused css

  • ignore, array items can be a string or a regexp

architechture

1.1.27

7 years ago

1.1.26

7 years ago

1.1.25

7 years ago

1.1.24

7 years ago

1.1.23

7 years ago

1.1.21

7 years ago

1.1.20

7 years ago

1.1.19

7 years ago

1.1.18

7 years ago

1.1.17

7 years ago

1.1.16

7 years ago

1.1.15

7 years ago

1.1.14

7 years ago

1.1.13

7 years ago

1.1.12

7 years ago

1.1.11

7 years ago

1.1.10

7 years ago

1.1.9

7 years ago

1.1.8

7 years ago

1.1.7

7 years ago

1.1.6

7 years ago

1.1.5

7 years ago

1.1.4

7 years ago

1.1.3

7 years ago

1.1.2

7 years ago

1.0.2

7 years ago

1.0.1

7 years ago

1.0.0

7 years ago