# multi-buffer-data-view

> A wrapper around the native DataView which can handle multiple ArrayBuffers.

Latest version **7.0.1** (published 2026-06-18) · MIT license · 0 weekly downloads

## Install

```sh
npm install multi-buffer-data-view
pnpm add multi-buffer-data-view
yarn add multi-buffer-data-view
bun add multi-buffer-data-view
```

## Health

**Score 60/100 (C)** — status: active.

Positive: has types; esm support; no vulnerabilities; high quality score.

Warnings: low downloads.

## Facts

| | |
|---|---|
| Version | 7.0.1 |
| Published | 2026-06-18 |
| First published | 2019-05-31 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | bundled |
| Module format | ESM + CommonJS |
| Node | >=22.22.2 |
| Dependencies | 2 |
| Unpacked size | 57.4 KB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| Author | Christoph Guttandin |
| Maintainers | chrisguttandin |
| Keywords | ArrayBuffer, DataView |

## Links

- npm: https://www.npmjs.com/package/multi-buffer-data-view
- Repository: https://github.com/chrisguttandin/multi-buffer-data-view
- Issues: https://github.com/chrisguttandin/multi-buffer-data-view/issues
- npm.io page: https://npm.io/package/multi-buffer-data-view

## Dependencies (2)

- [tslib](https://npm.io/package/tslib.md) ^2.8.1
- [@babel/runtime](https://npm.io/package/@babel/runtime.md) ^7.29.7

## Alternatives

- [flatbuffers](https://npm.io/package/flatbuffers.md) — 6.0M weekly downloads
- [jwt-simple](https://npm.io/package/jwt-simple.md) — 259.5K weekly downloads
- [@exodus/patch-broken-hermes-typed-arrays](https://npm.io/package/@exodus/patch-broken-hermes-typed-arrays.md) — 28.5K weekly downloads
- [@native-to-anchor/buffer-layout](https://npm.io/package/@native-to-anchor/buffer-layout.md) — 12.2K weekly downloads
- [binary-parser-encoder](https://npm.io/package/binary-parser-encoder.md) — 5.3K weekly downloads

## Recent versions

- 7.0.1 (latest) — 2026-06-18
- 7.0.0 — 2026-05-20
- 6.0.27 — 2026-03-17
- 6.0.26 — 2026-01-16
- 6.0.25 — 2026-01-09
- 6.0.24 — 2025-09-22
- 6.0.23 — 2025-08-17
- 6.0.22 — 2025-06-11
- 6.0.21 — 2025-05-13
- 6.0.20 — 2025-03-25
- 6.0.19 — 2025-03-12
- 6.0.18 — 2025-02-24
- 6.0.17 — 2025-01-07
- 6.0.16 — 2025-01-04
- 6.0.15 — 2024-11-01
- … 119 more at https://npm.io/package/multi-buffer-data-view/versions

## README

# multi-buffer-data-view

**A wrapper around the native DataView which can handle multiple ArrayBuffers.**

[![version](https://img.shields.io/npm/v/multi-buffer-data-view.svg?style=flat-square)](https://www.npmjs.com/package/multi-buffer-data-view)

This module provides a wrapper around the native DataView. But instead of supporting only one ArrayBuffer as the backing memory the `MultiBufferDataView` exported by this module can operate across multiple ArrayBuffers.

## Usage

The `multi-buffer-data-view` module is available on [npm](https://www.npmjs.com/package/multi-buffer-data-view) and can be installed as usual.

```shell
npm install multi-buffer-data-view
```

It exports only one class called `MultiBufferDataView` which can be imported like this:

```js
import { MultiBufferDataView } from 'multi-buffer-data-view';
```

A `MultiBufferDataView` behaves almost like a native DataView with the notable exception that it can handle multiple ArrayBuffers.

```js
const anArrayBuffer = new ArrayBuffer(23);
const anotherArrayBuffer = new ArrayBuffer(41);

new MultiBufferDataView([anArrayBuffer, anotherArrayBuffer]);
```

The little example above will create a `MultiBufferDataView` which uses all 64 bytes that are available in the given ArrayBuffers. However it is also possible to limit the range of accessible bytes by providing a `byteOffset` or a `byteLength` as additional arguments.

```js
new MultiBufferDataView([anArrayBuffer, anotherArrayBuffer], 12, 24);
```

When creating a `MultiBufferDataView` with the parameters above it will only use the last 11 bytes of the first ArrayBuffer and the first 13 bytes of the second ArrayBuffer.

---
_Source: https://npm.io/package/multi-buffer-data-view · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
