const Keyword

Syntax

const name1 = value1 [, name2 = value2 [, ... [, nameN = valueN]]];

nameN
The constant's name, which can be any legal identifier.

valueN
The constant's value. This can be any legal expression, including a function expression.

The destructuring assignment syntax can also be used to declare variables.

const { bar } = foo; // where foo = { bar:10, baz:12 };
/* This creates a constant with the name 'bar', which has a value of 10 */