Home >Web Front-end >Front-end Q&A >What does javascript annotation include?

What does javascript annotation include?

藏色散人
藏色散人Original
2022-01-19 15:03:014535browse

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!

Statement:
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn