Multi-line comments start with /* and end with */.
Any text between /* and */ will be ignored by JavaScript.
This example uses a multi-line comment (a comment block) to explain the code:
Sample Code
<!DOCTYPE html><html><body><h1id="myH"></h1><pid="myP"></p><script>/*
The code below will change
the heading with id = "myH"
and the paragraph with id = "myP"
*/document.getElementById("myH").innerHTML = "JavaScript Comments";
document.getElementById("myP").innerHTML = "My first paragraph.";
</script></body></html>
Related Searches to JavaScript Comments - Commenting Code in JavaScript
javascript statements examples javascript commentsjavascript comments documentationjavascript comments paramjavascript comments conventionjavascript comments pluginjavascript comments stylejavascript comments syntaxjavascript comments exampletwo types of javascript commentsjavascript comments for functionssingle line comment in javascripthow to comment in javascripthow to insert a comment that has more than one line?multiline comment in javascript shortcut vscodehtml commentreact js commentblock comment javascript