is-map-x
v2.1.2
Published
Detect whether or not an object is an ES6 Map.
Downloads
2,528
Maintainers
Readme
is-map-x
Detect whether or not an object is an ES6 Map.
module.exports(object)
⇒ boolean ⏏
Determine if an object
is a Map
.
Kind: Exported function
Returns: boolean - true
if the object
is a Map
,
else false
.
| Param | Type | Description | | ------ | --------------- | ------------------- | | object | * | The object to test. |
Example
import isMap from 'is-map-x';
const m = new Map();
console.log(isMap([])); // false
console.log(isMap(true)); // false
console.log(isMap(m)); // true