stream.finished
Polyfill for stream.finished in node versions < v10
node v10.0.0 added support for a built-in stream.finished
:
https://github.com/nodejs/node/pull/19828
This package provides the built-in stream.finished
in node v10.0.0 and later,
and a replacement in other environments.
This package implements the es-shim API
interface. It works in an ES3-supported environment and complies with the
spec.
Usage
Direct
const finished = require('stream.finished');
Shim
require('stream.finished/shim')();
const stream = require('stream');
or:
require('stream.finished/auto');
const stream = require('stream');