javascript-obfuscator 5.0.0 → 5.1.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +8 -0
- package/CLAUDE.md +1 -2
- package/README.md +19 -1
- package/dist/index.browser.js +1 -1
- package/dist/index.browser.js.map +1 -1
- package/dist/index.cli.js +1 -1
- package/dist/index.cli.js.map +1 -1
- package/dist/index.js +1 -1
- package/dist/index.js.map +1 -1
- package/package.json +2 -10
- package/typings/src/enums/logger/LoggingMessage.d.ts +3 -1
- package/typings/src/interfaces/logger/ILogger.d.ts +1 -0
- package/typings/src/interfaces/pro-api/IProApiClient.d.ts +1 -0
- package/typings/src/logger/Logger.d.ts +1 -0
- package/typings/src/pro-api/constants.d.ts +2 -0
- package/typings/src/utils/AdvertisementUtils.d.ts +17 -0
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,13 @@
|
|
|
1
1
|
Change Log
|
|
2
2
|
|
|
3
|
+
v5.1.0
|
|
4
|
+
---
|
|
5
|
+
* Add `version` parameter to the `apiConfig` to use different versions JavaScript Obfuscator Pro via API
|
|
6
|
+
|
|
7
|
+
v5.0.1
|
|
8
|
+
---
|
|
9
|
+
* Add JavaScript Obfuscator PRO advertisement message
|
|
10
|
+
|
|
3
11
|
v5.0.0
|
|
4
12
|
---
|
|
5
13
|
* Add JavaScript Obfuscator PRO support via calling its API
|
package/CLAUDE.md
CHANGED
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
|
|
5
5
|
**JavaScript Obfuscator** is a powerful, enterprise-grade code obfuscation tool for JavaScript and Node.js applications. It transforms readable JavaScript code into a protected, difficult-to-understand format while maintaining full functionality. The project is widely used for protecting intellectual property and preventing reverse engineering.
|
|
6
6
|
|
|
7
|
-
- **Version**:
|
|
7
|
+
- **Version**: 5.0.0
|
|
8
8
|
- **Author**: Timofey Kachalov (@sanex3339)
|
|
9
9
|
- **License**: BSD-2-Clause
|
|
10
10
|
- **Repository**: https://github.com/javascript-obfuscator/javascript-obfuscator
|
|
@@ -1423,7 +1423,6 @@ Use [grunt-contrib-obfuscator](https://github.com/javascript-obfuscator/grunt-co
|
|
|
1423
1423
|
|
|
1424
1424
|
- **GitHub Issues**: Bug reports and feature requests
|
|
1425
1425
|
- **GitHub Discussions**: Questions and general discussion
|
|
1426
|
-
- **OpenCollective**: Financial support and sponsorship
|
|
1427
1426
|
- **GitHub Sponsors**: Direct sponsorship
|
|
1428
1427
|
|
|
1429
1428
|
## License
|
package/README.md
CHANGED
|
@@ -6,7 +6,6 @@
|
|
|
6
6
|
|
|
7
7
|
#### You can support this project by donating:
|
|
8
8
|
* (Github) https://github.com/sponsors/sanex3339
|
|
9
|
-
* (OpenCollective) https://opencollective.com/javascript-obfuscator
|
|
10
9
|
|
|
11
10
|
Huge thanks to all supporters!
|
|
12
11
|
|
|
@@ -309,6 +308,7 @@ console.log(result.getObfuscatedCode());
|
|
|
309
308
|
* `apiConfig` (`Object`) – Pro API configuration:
|
|
310
309
|
* `apiToken` (`string`, required) – your API token from obfuscator.io
|
|
311
310
|
* `timeout` (`number`, optional) – request timeout in ms (default: `300000` - 5 minutes)
|
|
311
|
+
* `version` (`string`, optional) – JavaScript Obfuscator Pro version to use (e.g., `'5.0.0-beta.20'`). Defaults to latest version if not specified.
|
|
312
312
|
* `onProgress` (`function`, optional) – callback for progress updates during obfuscation
|
|
313
313
|
|
|
314
314
|
**Returns:** `Promise<ObfuscationResult>`
|
|
@@ -318,6 +318,24 @@ console.log(result.getObfuscatedCode());
|
|
|
318
318
|
- API token is invalid or expired
|
|
319
319
|
- API request fails
|
|
320
320
|
|
|
321
|
+
### Pro API with Specific Version
|
|
322
|
+
|
|
323
|
+
You can specify which obfuscator version to use via the `version` option:
|
|
324
|
+
|
|
325
|
+
```javascript
|
|
326
|
+
const result = await JavaScriptObfuscator.obfuscatePro(
|
|
327
|
+
sourceCode,
|
|
328
|
+
{
|
|
329
|
+
vmObfuscation: true,
|
|
330
|
+
vmObfuscationThreshold: 1
|
|
331
|
+
},
|
|
332
|
+
{
|
|
333
|
+
apiToken: 'your_javascript_obfuscator_pro_api_token',
|
|
334
|
+
version: '5.0.0-beta.20' // Use specific version
|
|
335
|
+
}
|
|
336
|
+
);
|
|
337
|
+
```
|
|
338
|
+
|
|
321
339
|
### Pro API with Progress Updates
|
|
322
340
|
|
|
323
341
|
The API uses streaming mode to provide real-time progress updates during obfuscation:
|