Skip to content

Commit

Permalink
auto generate gzip assets
Browse files Browse the repository at this point in the history
  • Loading branch information
kevinpapst committed Nov 6, 2024
1 parent d596844 commit 6fe9ba5
Show file tree
Hide file tree
Showing 7 changed files with 9 additions and 1 deletion.
Binary file added assets/build/9e2b21b135bc7d4c803f.svg.gz
Binary file not shown.
Binary file added assets/build/d12afc36557395143e4b.woff.gz
Binary file not shown.
Binary file added assets/build/db9ddb1898dbd76badca.ttf.gz
Binary file not shown.
Binary file added assets/build/main.css.gz
Binary file not shown.
Binary file added assets/build/main.js.gz
Binary file not shown.
Binary file added assets/build/main.rtl.css.gz
Binary file not shown.
10 changes: 9 additions & 1 deletion webpack.config.js
Original file line number Diff line number Diff line change
@@ -1,11 +1,19 @@
const path = require('path');
const MiniCssExtractPlugin = require("mini-css-extract-plugin");
const RtlCssPlugin = require("rtlcss-webpack-plugin");
const CompressionPlugin = require("compression-webpack-plugin");

module.exports = {
plugins: [
new MiniCssExtractPlugin(),
new RtlCssPlugin('main.rtl.css')
new RtlCssPlugin('main.rtl.css'),
new CompressionPlugin({
algorithm: 'gzip',
filename: '[path][base].gz',
test: /\.js$|\.css$|\.html$|\.svg$|\.eot$|\.woff$|\.woff2$|\.ttf$|\.txt$/,
threshold: 10240,
minRatio: 0.8
}),
],
entry: {
'main': __dirname + "/src/bundle.js",
Expand Down

0 comments on commit 6fe9ba5

Please sign in to comment.