MCPcopy Index your code
hub / github.com/immutable-js/immutable-js / isMap

Function isMap

src/predicates/isMap.ts:10–16  ·  view source on GitHub ↗
(maybeMap: unknown)

Source from the content-addressed store, hash-verified

8 * Also true for OrderedMaps.
9 */
10export function isMap(maybeMap: unknown): maybeMap is Map<unknown, unknown> {
11 return Boolean(
12 maybeMap &&
13 // @ts-expect-error: maybeMap is typed as `{}`, need to change in 6.0 to `maybeMap && typeof maybeMap === 'object' && IS_MAP_SYMBOL in maybeMap`
14 maybeMap[IS_MAP_SYMBOL]
15 );
16}

Callers 3

constructorMethod · 0.90
isOrderedMapFunction · 0.90
partition.tsFile · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected