When I run javascript script file in windows command line environment, and there is a free text coming after my code. How can I stop javascript interpreter to run into it?
For example:
var fso = new ActiveXObject("Scripting.FileSystemObject");
delete fso;
exit(); // some kind of WORKING exit command
Hungry lazy frog ate a big brown fox.
There is nothing you can do to stop the interpreter before it the compiler sees a particular line because the whole Javascript source file is first compiled to bytecode and it is the bytecode that is interpreted not your source code.
What you could do (though it would still be messy) would be to put some free text in a comment at the end of the file. Then you could open the source file and read it from the rest of the code. It still can’t be completely free text though as it would have to be a valid comment
Much better is simply to admit defeat and store any data you need in a separate file.