mirror of
https://github.com/luzhisheng/js_reverse.git
synced 2025-04-19 18:24:51 +08:00
17 lines
312 B
JavaScript
17 lines
312 B
JavaScript
const code = `
|
|
for (let i = 0; i < 5; i ++) {
|
|
console.log('i', i)
|
|
}
|
|
`
|
|
|
|
const options = {
|
|
debugProtection: true
|
|
}
|
|
|
|
const obfuscator = require('javascript-obfuscator')
|
|
|
|
function obfuscate(code, options) {
|
|
return obfuscator.obfuscate(code, options).getObfuscatedCode()
|
|
}
|
|
|
|
console.log(obfuscate(code, options)) |