Skip to content
This repository has been archived by the owner on Jun 30, 2023. It is now read-only.

Commit

Permalink
Compress assets
Browse files Browse the repository at this point in the history
  • Loading branch information
lujjjh committed Sep 22, 2021
1 parent 2dfe0a9 commit 836bad1
Show file tree
Hide file tree
Showing 8 changed files with 301 additions and 13 deletions.
3 changes: 0 additions & 3 deletions .vscode/settings.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,5 @@
"editor.defaultFormatter": "esbenp.prettier-vscode",
"[rust]": {
"editor.defaultFormatter": "matklad.rust-analyzer"
},
"files.exclude": {
"windows/": true
}
}
221 changes: 221 additions & 0 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 1 addition & 0 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -45,6 +45,7 @@
"prettier-plugin-style-order": "^0.2.2",
"typescript": "^4.4.2",
"vite": "^2.5.10",
"vite-plugin-compression": "^0.3.5",
"vite-react-jsx": "^1.1.2",
"wait-on": "^6.0.0"
}
Expand Down
8 changes: 0 additions & 8 deletions vite.config.js

This file was deleted.

18 changes: 18 additions & 0 deletions vite.config.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
import reactRefresh from '@vitejs/plugin-react-refresh'
import { defineConfig } from 'vite'
import compression from 'vite-plugin-compression'
import reactJsx from 'vite-react-jsx'

export default defineConfig(({ command }) => ({
plugins: [
reactRefresh(),
reactJsx(),
compression({
filter: /^/,
disable: command === 'serve',
threshold: 0,
ext: '.gz',
deleteOriginFile: true,
}),
],
}))
Loading

0 comments on commit 836bad1

Please sign in to comment.