In {{glossary("JavaScript")}}, a block is a collection of related {{glossary("statement","statements")}} enclosed in braces ("{}"). For example, you can put a block of statements after {{jsxref("Statements/if...else","if (condition)")}}, indicating that the interpreter must skip the whole block if the condition is false.
Learn more
Learn about it