reservedStrings: ['\s*'], // 解决\x20
new JavaScriptObfuscator({
// // 限制使用开发者工具的控制台选项卡
// debugProtection: true,
// // 使用间隔强制调试模式,从而更难使用“开发人员工具”的其他功能。
// debugProtectionInterval: true,
// // 禁用console.log,console.info,console.error和console.warn 阻碍攻击者调试
// disableConsoleOutput: true,
// 保证混淆后的代码,不能被代码格式化,需要配置 cpmpat:true;
selfDefending: true,
// 压缩,无换行
compact: true,
// 通过固定和随机(在代码混淆时生成)的位置移动数组。这使得将删除的字符串的顺序与其原始位置相匹配变得更加困难。如果原始源代码不小,建议使用此选项,因为辅助函数可以引起注意。
rotateStringArray: true,
// 禁用字符串文字的转换
reservedStrings: ['\s*'],
// 删除字符串文字并将它们放在一个特殊的数组中
stringArray: true,
stringArrayEncoding: [],
stringArrayThreshold: 1,
}, []),