By default source maps are disabled. Please use this feature with care, sending the Source Maps to production will expose your original code to everyone.
To use Source Maps you will have to setup a new option on your Jscrambler config (
sourceMaps). Source maps will be enabled if
sourceMaps resolve to any
For more information about RC configuration please refer to our Github documentation.
You can enable two distinct options when using source maps through Jscrambler’s API:
Source maps will include the original source code embedded in the source map file.
If you don’t want your original code to be included inside the source map you’ll have to explicitly set the
sourceContent option to
false. Therefore, the original file will need to be placed in the same directory as the source map.
If you don’t want Source Maps you can both set
sourceMaps flag to
false or simply omit the
For security reasons we have decided to not include the source maps alongside your code, so, after enabling them on your configuration file you will need to make a another request in order to download them.
Using the client, the protection process sends to the
protectionId which can be used to download the Source Maps executing the following command:
Your application source maps will be downloaded to a folder named
jscramblerSourceMaps found in the destination folder.
bundle.js.map to Jscrambler.
Also, make sure that source maps files are in the same directory as their respective source code files.
After that, the process is exactly the same as described in the previous sections.