Logo

Programming-Idioms

History of Idiom 8 > diff from v48 to v49

Edit summary for version 49 by yuchi:
[JS] follow the standard "x" notation for variable names

Version 48

2019-09-26, 14:56:39

Version 49

2019-09-26, 14:56:58

Idiom #8 Initialize a new map (associative array)

Declare a new map object x, and provide some (key, value) pairs as initial content.

Idiom #8 Initialize a new map (associative array)

Declare a new map object x, and provide some (key, value) pairs as initial content.

Extra Keywords
table dictionary hash
Extra Keywords
table dictionary hash
Code
const map = new Map();
Code
const x = new Map();
Comments bubble
From ES2015
Comments bubble
From ES2015
Doc URL
https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Map
Doc URL
https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Map