mirror of
https://github.com/javascript-obfuscator/javascript-obfuscator
synced 2026-08-09 12:42:29 +00:00
The splitStrings option now correctly splits strings inside objects
This commit is contained in:
+6
-4
@@ -6,16 +6,18 @@ import { NO_ADDITIONAL_NODES_PRESET } from '../../src/options/presets/NoCustomNo
|
||||
|
||||
let obfuscatedCode: string = JavaScriptObfuscator.obfuscate(
|
||||
`
|
||||
var n = 'abcefgi';
|
||||
function hi() {
|
||||
console.log("Hello World!");
|
||||
}
|
||||
hi();
|
||||
`,
|
||||
{
|
||||
...NO_ADDITIONAL_NODES_PRESET,
|
||||
compact: false,
|
||||
splitStrings: true,
|
||||
splitStringsChunkLength: 4,
|
||||
stringArray: true,
|
||||
stringArrayThreshold: 1,
|
||||
seed: 1
|
||||
controlFlowFlattening: true,
|
||||
controlFlowFlatteningThreshold: 1
|
||||
}
|
||||
).getObfuscatedCode();
|
||||
|
||||
|
||||
Reference in New Issue
Block a user