Syntax
- new Map([iterable])
- map.set(key, value)
- map.get(key)
- map.size
- map.clear()
- map.delete(key)
- map.entries()
- map.keys()
- map.values()
- map.forEach(callback[, thisArg])
Parameters
Untitled Database
Remarks
In Maps NaN
is considered to be the same as NaN
, even though NaN !== NaN
. For example:
const map = new Map([[NaN, true]]);
console.log(map.get(NaN)); // true
Creating a Map
Clearing a map