Statements (JavaScript)

JavaScript statements consist of keywords and syntax.

  • A single statement may span multiple lines.
  • Multiple statements may occur on one line separated by semicolons.
  • A semicolon may optionally terminate the last statement on a line.
See the ECMA specification (http://www.ecma-international.org/publications/standards/Ecma-262.htm) for a description of the statements. Note the following exceptions:
  • import (implementation-specific) is supported to import code from a script library. See import (JavaScript).
  • export (implementation-specific and not in the ECMA standard) is not supported.
  • label (not considered good programming) is not supported.