diff --git a/Caddyfile b/Caddyfile index d20e1fb..b277ebc 100644 --- a/Caddyfile +++ b/Caddyfile @@ -12,6 +12,7 @@ try_files {path} /index.html file_server { + # TODO: 由于 Bun 标准库实现问题,暂时禁用 Brotli 压缩 precompressed gzip } } diff --git a/frontend/vite.config.ts b/frontend/vite.config.ts index a100624..c6b098d 100644 --- a/frontend/vite.config.ts +++ b/frontend/vite.config.ts @@ -55,14 +55,12 @@ export default defineConfig({ navigateFallbackDenylist: [/^\/api.*/], }, }), - // GZip - compression({ threshold: 4096 }), - // Brotli - compression({ - algorithm: "brotliCompress", - threshold: 4096, - ext: ".br", - }), + compression({ algorithm: "gzip" }), + // TODO: 由于 Bun 标准库实现问题,暂时禁用 Brotli 压缩 + // compression({ + // algorithm: "brotliCompress", + // ext: ".br", + // }), ], server: { proxy: {