-
Notifications
You must be signed in to change notification settings - Fork 101
/
Copy pathjavascript-obfuscator.d.ts
41 lines (39 loc) · 1.13 KB
/
javascript-obfuscator.d.ts
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
declare module "javascript-obfuscator" {
namespace JavaScriptObfuscator {
interface Options {
compact?: boolean
controlFlowFlattening?: boolean
controlFlowFlatteningThreshold?: 0.75
deadCodeInjection?: boolean
deadCodeInjectionThreshold?: 0.4
debugProtection?: boolean
debugProtectionInterval?: boolean
disableConsoleOutput?: boolean
domainLock?: string[]
identifierNamesGenerator?: "hexadecimal" | "mangled"
log?: boolean
renameGlobals?: boolean
reservedNames?: string[]
rotateStringArray?: true
seed?: 0
selfDefending?: boolean
sourceMap?: boolean
sourceMapBaseUrl?: string
sourceMapFileName?: string
sourceMapMode?: "separate" | "inline"
stringArray?: boolean
stringArrayEncoding?: string[]
stringArrayThreshold?: 0.75
target?: "browser" | "extension" | "node"
unicodeEscapeSequence?: boolean
}
function obfuscate(
sourceCode: string,
options: Options,
): {
getObfuscatedCode(): string
getSourceMap(): string | null
}
}
export = JavaScriptObfuscator
}