Skip to main content
isWeakMap - node__util--types.d.ts - Node documentation
function isWeakMap

Usage in Deno

```typescript import { isWeakMap } from "node:node__util--types.d.ts"; ```
isWeakMap(object: unknown): object is WeakMap<object, unknown>
Returns `true` if the value is a built-in [`WeakMap`](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/WeakMap) instance. ```js util.types.isWeakMap(new WeakMap()); // Returns true ```

Parameters

object: unknown

Return Type

object is WeakMap<object, unknown>