iterable-to-stream

Converts iterable objects into readable streams.

Usage no npm install needed!

<script type="module">
  import iterableToStream from 'https://cdn.skypack.dev/iterable-to-stream';
</script>

README

iterable-to-stream

Convert iterable objects into node readable streams.

import iterableToStream from 'iterable-to-stream';

iterableToStream(['one', 'two', 'three']).pipe(process.stdout);

Note

With version 10, Node introduced stream.Readable.from which converts an iterator to a stream.

This library will use the Node version if it is available.

Notice of Deprecation

This library will be deprecated when Node 12 is deprecated.

Supported Node Versions

  • 12.x, 14.x, 15.x
  • Unsupported, but should still work: 8.x, 10.x