JavaScript: Map.prototype.size

By Xah Lee. Date: . Last updated: .

New in JS2015.

map_obj.size
Return the total count of entries in map_obj.
console.log(
(new Map([[3, "n3"], [4, "n4"]])).size === 2
);
// true
JS in Depth
XAH  BUY NOW

JS in Depth

JS Obj Ref

DOM


JS Obj Ref

Map

prototype