# readable-stream-node-to-web

> Converts a node Readable stream to a web ReadableStream

Latest version **1.0.1** (published 2017-08-03) · MIT license · 0 weekly downloads

## Install

```sh
npm install readable-stream-node-to-web
pnpm add readable-stream-node-to-web
yarn add readable-stream-node-to-web
bun add readable-stream-node-to-web
```

## 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 | 2017-08-03 |
| First published | 2017-08-02 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | none |
| Module format | CommonJS |
| Dependencies | 0 |
| Known vulnerabilities | 0 |
| Install scripts | no |
| GitHub stars | 12 |
| Author | xuset |
| Maintainers | xuset |
| Keywords | readable, stream, readablestream, node, web, whatwg |

## Links

- npm: https://www.npmjs.com/package/readable-stream-node-to-web
- Repository: https://github.com/xuset/readable-stream-node-to-web
- Homepage: https://github.com/xuset/readable-stream-node-to-web#readme
- Issues: https://github.com/xuset/readable-stream-node-to-web/issues
- npm.io page: https://npm.io/package/readable-stream-node-to-web

## Alternatives

- [byte-size](https://npm.io/package/byte-size.md) — 2.1M weekly downloads
- [speed-limiter](https://npm.io/package/speed-limiter.md) — 16.0K weekly downloads
- [@powersync/node](https://npm.io/package/@powersync/node.md) — 10.9K weekly downloads
- [@ledgerhq/coin-cardano](https://npm.io/package/@ledgerhq/coin-cardano.md) — 1.0K weekly downloads
- [@jayesol/jayeson.lib.streamfinder](https://npm.io/package/@jayesol/jayeson.lib.streamfinder.md) — 1.0K weekly downloads

## Recent versions

- 1.0.1 (latest) — 2017-08-03
- 1.0.0 — 2017-08-02

## README

# readable-stream-node-to-web [![Build Status](https://travis-ci.org/xuset/readable-stream-node-to-web.svg?branch=master)](https://travis-ci.org/xuset/readable-stream-node-to-web) [![npm](https://img.shields.io/npm/v/readable-stream-node-to-web.svg)](https://npmjs.org/package/readable-stream-node-to-web)

#### Convert a nodejs Readable stream to a web ReadableStream

[![Sauce Test Status](https://saucelabs.com/browser-matrix/xuset-readable-stream-node-to-web.svg)](https://saucelabs.com/u/xuset-readable-stream-node-to-web)


```js
var nodeToWebStream = require('readable-stream-node-to-web');

var nodeStream = // Obtain a nodejs Readable stream
var webStream = nodeToWebStream(nodeStream);
```

`nodeStream` is a [NodeJS Readable stream](https://nodejs.org/api/stream.html#stream_readable_streams)

`webStream` is a [WhatWG web ReadableStream](https://streams.spec.whatwg.org/#rs-class)

This method takes a readable node stream and returns a web stream to reads from given the node stream. This allows the plethora of nodejs modules involving Readable streams to be used in a web context like using a node stream with [FetchEvent.respondWith()](https://developer.mozilla.org/en-US/docs/Web/API/FetchEvent/respondWith)

This module can be used with bundlers like browserify or webpack. This module is also written in es5 so there is no need for transpilation.

## License

MIT. Copyright (c) Austin Middleton.

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