# @foxglove/wasm-bz2

> Bzip2 decompression compiled to WebAssembly

Latest version **0.3.0** (published 2026-02-17) · MIT license · 0 weekly downloads

## Install

```sh
npm install @foxglove/wasm-bz2
pnpm add @foxglove/wasm-bz2
yarn add @foxglove/wasm-bz2
bun add @foxglove/wasm-bz2
```

## Health

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

Positive: has types; no vulnerabilities; has provenance; high quality score.

Warnings: low downloads; no esm support; pre 1.0.

## Facts

| | |
|---|---|
| Version | 0.3.0 |
| Published | 2026-02-17 |
| First published | 2021-07-14 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | bundled |
| Module format | CommonJS |
| Dependencies | 1 |
| Unpacked size | 1.2 MB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| Provenance | attested (GitHub Actions) |
| GitHub stars | 6 |
| Author | Foxglove |
| Maintainers | foxglovebot, amacneil |

## Links

- npm: https://www.npmjs.com/package/@foxglove/wasm-bz2
- Repository: https://github.com/foxglove/wasm-bz2
- Homepage: https://github.com/foxglove/wasm-bz2#readme
- Issues: https://github.com/foxglove/wasm-bz2/issues
- npm.io page: https://npm.io/package/@foxglove/wasm-bz2

## Dependencies (1)

- [tslib](https://npm.io/package/tslib.md) ^2

## Recent versions

- 0.3.0 (latest) — 2026-02-17
- 0.2.0 — 2026-02-17
- 0.1.1 — 2022-11-30
- 0.1.0 — 2021-12-23
- 0.0.4 — 2021-07-14
- 0.0.3 — 2021-07-14
- 0.0.2 — 2021-07-14
- 0.0.1 — 2021-07-14

## README

# @foxglove/wasm-bz2

[![npm version](https://img.shields.io/npm/v/@foxglove/wasm-bz2)](https://www.npmjs.com/package/@foxglove/wasm-bz2)

Bzip2 decompression compiled to WebAssembly

## Introduction

This package provides a WebAssembly build of https://gitlab.com/bzip2/bzip2, the official Bzip2 library. Currently only a decompression function is provided.

## Usage

```ts
import Bzip2 from "@foxglove/wasm-bz2";

const bzip2 = await Bzip2.init();

try {
  const buffer = new Uint8Array([...]);
  const maxSize = 100;
  const decompressedBuffer = Bzip2.decompress(buffer, maxSize, { small: false });
} catch (error) {
  console.error(error);
}
```

## Stay in touch

Join our [Slack channel](https://foxglove.dev/slack) to ask questions, share feedback, and stay up to date on what our team is working on.

---
_Source: https://npm.io/package/@foxglove/wasm-bz2 · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
