Web Streams, based on the WHATWG spec reference implementation.
For node.js / browserify users:
var streams = require("web-streams-polyfill");
var readable = new streams.ReadableStream;
// Or, in ES6
import { ReadableStream } from "web-streams-polyfill";
For use as polyfill, include the dist/polyfill.min.js
file in your html before your main script.
<script src="/path/to/polyfill.min.js"></script>
<script type="text/javascript">
var readable = new window.ReadableStream;
</script>
Thanks to these people for their contributions:
- Anders Riutta ariutta