npm.io
2.0.4 • Published 5 years ago

final-stream

Licence
MIT
Version
2.0.4
Deps
0
Size
16 kB
Vulns
0
Weekly
0
Stars
1

Final Stream

GitHub code size in bytes GitHub package.json version GitHub

A tool to read a full stream and callback once finished with the data

Example Usage

With callbacks

const finalStream = require('final-stream');
finalStream(request, function (error, result) {
  console.log(error, result.toString());
});
With promises
const finalStream = require('final-stream');
const result = await finalStream(request);
console.log(result.toString());

License

This project is licensed under the terms of the MIT license.