Enable compress without dropping debugger to avoid SyntaxError in safari 16 {to #1766} (#2825)

This commit is contained in:
lichen
2024-06-07 23:11:52 +08:00
committed by GitHub
parent 98341b440a
commit 026194e5e2
2 changed files with 9 additions and 1 deletions

View File

@@ -73,7 +73,9 @@ module.exports = {
// `terserOptions` options will be passed to `swc` (`@swc/core`)
// Link to options - https://swc.rs/docs/config-js-minify
terserOptions: {
compress: false,
compress: {
drop_debugger: false,
},
mangle: true,
},
}),

View File

@@ -0,0 +1,6 @@
---
category: Bugfix
authors: [chinalichen]
---
Enable compress to avoid minified scripts from throwing SyntaxError in safari16