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

Usage in Deno

```typescript import { isArrayBuffer } from "node:node__util--types.d.ts"; ```
isArrayBuffer(object: unknown): object is ArrayBuffer
Returns `true` if the value is a built-in [`ArrayBuffer`](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/ArrayBuffer) instance. This does _not_ include [`SharedArrayBuffer`](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/SharedArrayBuffer) instances. Usually, it is desirable to test for both; See `util.types.isAnyArrayBuffer()` for that. ```js util.types.isArrayBuffer(new ArrayBuffer()); // Returns true util.types.isArrayBuffer(new SharedArrayBuffer()); // Returns false ```

Parameters

object: unknown

Return Type

object is ArrayBuffer