Language concepts

Short-circuit evaluation

Try the free JavaScript compiler

Logical AND, OR and nullish coalescing may omit evaluation of the right expression. A skipped expression has no side effects and cannot throw from its own evaluation.

Formal Syntax & Structure

javascript syntaxjavascript
left && right

Working Example

Example Snippetjavascript
let n = 0; false && ++n; console.log(n);
JavaScript Reference