feat: added brotli|gzip compression and related test commands

This commit is contained in:
vben
2021-02-13 00:26:41 +08:00
parent d7531554a2
commit 993538de21
11 changed files with 225 additions and 91 deletions

View File

@@ -30,13 +30,15 @@ export default ({ command, mode }: ConfigEnv): UserConfig => {
return {
base: VITE_PUBLIC_PATH,
root,
alias: [
{
// /@/xxxx => src/xxx
find: /^\/@\//,
replacement: pathResolve('src') + '/',
},
],
resolve: {
alias: [
{
// /@/xxxx => src/xxx
find: /^\/@\//,
replacement: pathResolve('src') + '/',
},
],
},
server: {
port: VITE_PORT,
// Load proxy configuration from .env
@@ -88,6 +90,7 @@ export default ({ command, mode }: ConfigEnv): UserConfig => {
optimizeDeps: {
// @iconify/iconify: The dependency is dynamically and virtually loaded by @purge-icons/generated, so it needs to be specified explicitly
include: ['@iconify/iconify'],
exclude: ['vue-demi'],
},
};
};