How To Add comments to your JavaScript
JavaScript Support Comment ?
JavaScript supports a one-line comment with the double slash (//) marker so you can add comment to you javascript, which means that JavaScript doesn’t read anything on a line after // javascript can't not be run or progress. if you want to add comments for people to read throughout your code, and they won’t interrupt how your JavaScript runs. See the comment line added in bold in the following code:
//Comment write here...... using // for commentdocument.write(“Text PopUp”);A First Script
I want to add several line comment ?
In fact, JavaScript also supports a second type of comment or several comment, which you can
use for multiple lines. This comment starts with /* and ends with */. When
JavaScript sees /*, it ignores everything else until it sees */. Here’s an
example:
A First Script /* Multi linecomment here.... */document.write(“Text PopUp Here”);A First Script
now you can add comment in your javascript!!!