Changes

Jump to: navigation, search

Comments in JavaScript

3 bytes added, 14:16, 30 May 2007
Multi-line Comments
== Multi-line Comments ==
For the purposes of supporting comments that extend over multiple lines JavaScript borrowed some syntac syntax from the C programming language. The start and end of lines of comments are marked by the /* and */ markers respectively. Everything immediately after the /* and befre before the */ is considered to be a comment, regardless of where the markers appear on a line. For example:
<pre>
</pre>
Multi-line comments are particularly useful for commenting out sections of a script you no longer wish to run but do not yet wish to delete, together with an explanation of when and why you have comment commented it out:
<pre>

Navigation menu