mirror of
https://github.com/javascript-obfuscator/javascript-obfuscator
synced 2026-08-09 12:42:29 +00:00
Updated README.md
This commit is contained in:
+9
-9
@@ -7,20 +7,20 @@ import { NO_ADDITIONAL_NODES_PRESET } from '../../src/options/presets/NoCustomNo
|
||||
|
||||
let obfuscatedCode: string = JavaScriptObfuscator.obfuscate(
|
||||
`
|
||||
var x = {
|
||||
baz_: 0,
|
||||
foo_: 1,
|
||||
calc: function() {
|
||||
return this.foo_ + this.baz_;
|
||||
const foo = {
|
||||
prop1: 1,
|
||||
prop2: 2,
|
||||
calc: function () {
|
||||
return this.prop1 + this.prop2;
|
||||
}
|
||||
};
|
||||
x.bar_ = 2;
|
||||
x["baz_"] = 3;
|
||||
console.log(x.calc());
|
||||
|
||||
console.log(foo.calc());
|
||||
`,
|
||||
{
|
||||
...NO_ADDITIONAL_NODES_PRESET,
|
||||
compact: false
|
||||
compact: false,
|
||||
renameProperties: true
|
||||
}
|
||||
).getObfuscatedCode();
|
||||
|
||||
|
||||
Reference in New Issue
Block a user