Creates the source code of a script from a script's compiled form.
JSAPI 1 and earlier
| || ||The context to use to decompile the script. Requires request. In a |
| || ||Script to decompile.|
| || ||Name to assign to the decompiled script.|
| || ||Number of spaces to use for indented code.|
JS_DecompileScript creates the source code version of a script from a script's compiled form,
name is the name you assign to the text version of the script; it is used only for debugging the source code version produced by this function.
JS_DecompileScript returns a string containing the source code of the script. Otherwise, it returns
NULL. The source code generated by this function is accurate but lacks function declarations. In order to make it suitable for recompiling, you must edit the code to add the function declarations, or call
JS_DecompileFunction on a compiled version of each function to generate the function declarations.