Home >Web Front-end >Front-end Q&A >What does javascript annotation include?
Javascript comments include three types, namely: 1. Multi-line comments, the symbol is "/**/"; 2. Single-line comments, the symbol is "//"; 3. Single-line comments, the symbol is "ef471b7cfa65a3930bd85e501dbc1f01, this is different from html comments.
Summary:
It is recommended that you use the first method of multi-line comments. As for why? If you want to comment 100 lines of code, just add comments at the beginning and end. If you need to use the second method, you have to add comments on each line, which will increase the number of bytes in the file.
Recommended study: "JS Basic Tutorial"
The above is the detailed content of What does javascript annotation include?. For more information, please follow other related articles on the PHP Chinese website!