728x90
SMALL
#Javascript
One-line comment
Create a one-line comment with //.
// single line comment
// Before, it's processed by code, // After that, it's processed by comments.
for example
var jb = 'hi'; // Comment
var jb ='hi'; is recognized as code.
Multi-line comment
If you want to comment out multiple lines, enclose them in / * and * /.
/*
Comment 1
Comment 2
*/
It may be easier to read and may look like this:
/*
* Comment 1
* Comment 2
*/
Points to note
All JavaScript comments you put into your HTML document are visible when you look at the Source view. Therefore, if you have comments that you created during development but should not be published, we recommend that you remove them.
728x90
LIST
'Javascript' 카테고리의 다른 글
[JavaScript] JavaScript/operator/typeof operator (0) | 2022.08.01 |
---|---|
[Javascript] JavaScript / operator / comparison operator (0) | 2022.07.29 |
[Javascript] JavaScript / data type / string (0) | 2022.07.29 |
[Javascript] How to put the syntax (0) | 2022.07.27 |
[Javascript] How to insert JavaScript into an HTML document (0) | 2022.07.27 |