Lexical syntax

JavaScript block comment

Try the free JavaScript compiler

A block comment begins with slash-star and ends with star-slash. It can span lines but cannot nest. A line terminator inside it can affect automatic semicolon insertion.

Formal Syntax & Structure

javascript syntaxjavascript
/* comment */

Working Example

Example Snippetjavascript
/* Show a fixed value. */console.log(4);
JavaScript Reference