# lz4-offset-stream

> Stream that emits offsets of lz4 encoded payloads

Latest version **1.0.1** (published 2021-06-25) · MIT license · 0 weekly downloads

## Install

```sh
npm install lz4-offset-stream
pnpm add lz4-offset-stream
yarn add lz4-offset-stream
bun add lz4-offset-stream
```

## Health

**Score 15/100 (F)** — status: abandoned.

Positive: no vulnerabilities.

Warnings: low downloads; no types; no esm support.

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 1.0.1 |
| Published | 2021-06-25 |
| First published | 2021-06-25 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | none |
| Module format | CommonJS |
| Dependencies | 0 |
| Unpacked size | 7.3 KB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| GitHub stars | 1 |
| Author | Evan Lucas |
| Maintainers | evanlucas, asimplesaurus |

## Links

- npm: https://www.npmjs.com/package/lz4-offset-stream
- Repository: https://github.com/evanlucas/lz4-offset-stream
- Issues: https://github.com/evanlucas/lz4-offset-stream/issues
- npm.io page: https://npm.io/package/lz4-offset-stream

## Recent versions

- 1.0.1 (latest) — 2021-06-25
- 1.0.0 — 2021-06-25

## README

# lz4-offset-stream

> Node.js stream that emits lz4 segment offsets

Ever wanted to try and recover a file containing lz4 segments?
If so, this is for you. This is a node Transform stream that emits data events.
The argument emitted in the data event is a number, which is the start offset of a
lz4 segment.

## Install

```console
$ npm install [--save] lz4-offset-stream
```

## Tests

```console
$ npm test
```

## Usage

```js
'use strict'

const stream = require('stream')
const fs = require('fs')
const OffsetStream = require('lz4-offset-stream')

const start = process.env.OFFSET
  ? +process.env.OFFSET
  : 0

const fd = fs.createWriteStream('./file', {start})
const decoder = new OffsetStream({start})
pipeline(fd, decoder, process.stdout, (err) => {
  console.log('done', err)
})
```

## License

SEE LICENSE IN LICENSE

## Author

Evan Lucas

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