2.0.3 • Published 2 months ago

is-map v2.0.3

Weekly downloads
3,266,796
License
MIT
Repository
github
Last release
2 months ago

is-map Version Badge

github actions coverage dependency status dev dependency status License Downloads

npm badge

Is this value a JS Map? This module works cross-realm/iframe, and despite ES6 @@toStringTag.

Example

var isMap = require('is-map');
assert(!isMap(function () {}));
assert(!isMap(null));
assert(!isMap(function* () { yield 42; return Infinity; });
assert(!isMap(Symbol('foo')));
assert(!isMap(1n));
assert(!isMap(Object(1n)));

assert(!isMap(new Set()));
assert(!isMap(new WeakSet()));
assert(!isMap(new WeakMap()));

assert(isMap(new Map()));

class MyMap extends Map {}
assert(isMap(new MyMap()));

Tests

Simply clone the repo, npm install, and run npm test

es-get-iteratoreasy-select-rnreact-native-printer-brothersreact-native-shekhar-bridge-test@oiti/documentoscopy-react-nativequoc-test@infinitebrahmanuniverse/nolb-is-m@saaspe/componentsexpand-react-bridgeluminos-ui-coresklif-ui-kitsklif-api@everything-registry/sub-chunk-1934jawwy-sdkjawwy_gamification_release@deepakorg/test@deepak757/testreact-native-sphereuisphereuijawwy_libraryreact-native-credit-card-pkgp149-tablesklif-uimachinebeemrcapsreact-native-jawwy_sample@davidrockefeller/pixelpioneerwaniexxzatywartakjilwawjakwjwdio-cucumber@girhan/moko@extrieve_technologies/quickcapture_react_native@img-arena/img-ui-mui-theme@img-arena/ui-core@idas1/ui-component-lib@ifanshx/cycgods@imrtoy/homebridge-night-light@lxxtea/teababibikinpusing@joaquinmr99/calculadora@luciadias/storybook-notimation@jockho-gus/jp-geden@juanaraneta/dept-central-lib-client@firstday/firstdayteh@itayn-fireberry-org/itayn-testdynamics-contracts-x@asiz33/smartblok-vendure-plugin@hieuquang2212/form@jfilipe-sparta/react-native-module_2@jleiva/signer-jwt@kylesferrazza/graphql-relay-updated@mihai.stanica/stanikione@mihai.stanica/stanikitwoelviraes-react-bridgeerikoalamerlocogonzales08@npm_fluentco/adflow-react-native-sdk@navabi/react-native-ssl-pinning@oiti/rn-liveness2d@object-studio/react-native-webjawwy_library_newjawy_library_v1gamification-jawwy-libraryframework_test_library_sixdee_new_jawwytest_lib_module_aartea-fairly@gericuz/tea-fairlyzzzxxxyyy321123anci-reactparvan_componentsreact-native-tone-frameworkronaldocr7vibespixiu-swap-corepixiuswap-libs-sdkpixelpioneerpnm-yph-react-native-custom-componentspetengpickupbiz-npm-packageokemdevparvan_reactjs_componentsoregcahcldoxygenosp147-tablep148-tablepadangpedrosaletme22peachmelovers29patrisiomorales75pizza-teapolospolyglot-component-librarypopoqtest-library-123test-haptik-libtempebaladotetbekthuroteathomasidasajatest-zeo-collect
2.0.3

2 months ago

2.0.2

3 years ago

2.0.1

4 years ago

2.0.0

4 years ago

1.0.1

9 years ago

1.0.0

9 years ago