basant307/AI_Governance_Project
048
1# readable-stream2 3**_Node.js core streams for userland_**4 5[](https://npm.im/readable-stream)6[](https://www.npmjs.org/package/readable-stream)7[](https://github.com/nodejs/readable-stream/actions?query=workflow%3ANode.js)8[](https://github.com/nodejs/readable-stream/actions?query=workflow%3ABrowsers)9 10```bash11npm install readable-stream12```13 14This package is a mirror of the streams implementations in Node.js 18.19.0.15 16Full documentation may be found on the [Node.js website](https://nodejs.org/dist/v18.19.0/docs/api/stream.html).17 18If you want to guarantee a stable streams base, regardless of what version of19Node you, or the users of your libraries are using, use **readable-stream** _only_ and avoid the _"stream"_ module in Node-core, for background see [this blogpost](http://r.va.gg/2014/06/why-i-dont-use-nodes-core-stream-module.html).20 21As of version 2.0.0 **readable-stream** uses semantic versioning.22 23## Version 4.x.x24 25v4.x.x of `readable-stream` is a cut from Node 18. This version supports Node 12, 14, 16 and 18, as well as evergreen browsers.26The breaking changes introduced by v4 are composed of the combined breaking changes in:27* [Node v12](https://nodejs.org/en/blog/release/v12.0.0/)28* [Node v13](https://nodejs.org/en/blog/release/v13.0.0/)29* [Node v14](https://nodejs.org/en/blog/release/v14.0.0/)30* [Node v15](https://nodejs.org/en/blog/release/v15.0.0/)31* [Node v16](https://nodejs.org/en/blog/release/v16.0.0/)32* [Node v17](https://nodejs.org/en/blog/release/v17.0.0/)33* [Node v18](https://nodejs.org/en/blog/release/v18.0.0/)34 35This also includes _many_ new features.36 37## Version 3.x.x38 39v3.x.x of `readable-stream` is a cut from Node 10. This version supports Node 6, 8, and 10, as well as evergreen browsers, IE 11 and latest Safari. The breaking changes introduced by v3 are composed by the combined breaking changes in [Node v9](https://nodejs.org/en/blog/release/v9.0.0/) and [Node v10](https://nodejs.org/en/blog/release/v10.0.0/), as follows:40 411. Error codes: https://github.com/nodejs/node/pull/13310,42 https://github.com/nodejs/node/pull/13291,43 https://github.com/nodejs/node/pull/16589,44 https://github.com/nodejs/node/pull/15042,45 https://github.com/nodejs/node/pull/15665,46 https://github.com/nodejs/readable-stream/pull/344472. 'readable' have precedence over flowing48 https://github.com/nodejs/node/pull/18994493. make virtual methods errors consistent50 https://github.com/nodejs/node/pull/18813514. updated streams error handling52 https://github.com/nodejs/node/pull/18438535. writable.end should return this.54 https://github.com/nodejs/node/pull/18780556. readable continues to read when push('')56 https://github.com/nodejs/node/pull/18211577. add custom inspect to BufferList58 https://github.com/nodejs/node/pull/17907598. always defer 'readable' with nextTick60 https://github.com/nodejs/node/pull/1797961 62## Version 2.x.x63 64v2.x.x of `readable-stream` is a cut of the stream module from Node 8 (there have been no semver-major changes from Node 4 to 8). This version supports all Node.js versions from 0.8, as well as evergreen browsers and IE 10 & 11.65 66# Usage67 68You can swap your `require('stream')` with `require('readable-stream')`69without any changes, if you are just using one of the main classes and70functions.71 72```js73const {74 Readable,75 Writable,76 Transform,77 Duplex,78 pipeline,79 finished80} = require('readable-stream')81```82 83Note that `require('stream')` will return `Stream`, while84`require('readable-stream')` will return `Readable`. We discourage using85whatever is exported directly, but rather use one of the properties as86shown in the example above.87 88## Usage In Browsers89 90You will need a bundler like [`browserify`](https://github.com/browserify/browserify#readme), [`webpack`](https://webpack.js.org/), [`parcel`](https://github.com/parcel-bundler/parcel#readme) or similar. Polyfills are no longer required since version 4.2.0.91 92# Streams Working Group93 94`readable-stream` is maintained by the Streams Working Group, which95oversees the development and maintenance of the Streams API within96Node.js. The responsibilities of the Streams Working Group include:97 98- Addressing stream issues on the Node.js issue tracker.99- Authoring and editing stream documentation within the Node.js project.100- Reviewing changes to stream subclasses within the Node.js project.101- Redirecting changes to streams from the Node.js project to this102 project.103- Assisting in the implementation of stream providers within Node.js.104- Recommending versions of `readable-stream` to be included in Node.js.105- Messaging about the future of streams to give the community advance106 notice of changes.107 108<a name="members"></a>109 110## Team Members111 112- **Mathias Buus** ([@mafintosh](https://github.com/mafintosh)) <mathiasbuus@gmail.com>113- **Matteo Collina** ([@mcollina](https://github.com/mcollina)) <matteo.collina@gmail.com>114 - Release GPG key: 3ABC01543F22DD2239285CDD818674489FBC127E115- **Robert Nagy** ([@ronag](https://github.com/ronag)) <ronagy@icloud.com>116- **Vincent Weevers** ([@vweevers](https://github.com/vweevers)) <mail@vincentweevers.nl>117 