compression-asset-by-brotli-webpack-plugin
v0.0.2
Published
Compress assets by Brotli to serve them with Content-Encoding: br
Downloads
2
Readme
CompressAssetByBrotliWebpackPlugin
Compress assets by Brotli to serve them with Content-Encoding: br
Install
npm i compression-asset-by-brotli-webpack-plugin
Import
var CompressionAssetByBrotliWebpackPlugin = require('compression-asset-by-brotli-webpack-plugin');
Usage
new CompressionAssetByBrotliWebpackPlugin({
asset: '[path].br[query]',
test: /\.(js|css|html|svg)$/,
threshold: 5000,
minRatio: 0.8
})
Reference
https://github.com/google/brotli
https://github.com/MayhemYDG/iltorb#brotliencodeparams