Skip to content
Prev Previous commit
Next Next commit
前端:打包发布去除console信息
  • Loading branch information
4linuxfun committed Jan 31, 2023
commit 3f4d46e68c4216cf22b525c32cb0b27bab60b3a1
8 changes: 8 additions & 0 deletions www/vite.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -59,6 +59,14 @@ export default defineConfig({
},
build: {
outDir: 'dist',
minify: 'terser',
terserOptions: {
compress: {
//发布关闭调试模式
drop_console: true,
drop_debugger: true,
},
},
},
css: {}

Expand Down