An open API service indexing awesome lists of open source software.

https://github.com/grantila/stream-conclusion

Analyses streams to summarize the number of chunks and bytes passed
https://github.com/grantila/stream-conclusion

Last synced: 8 months ago
JSON representation

Analyses streams to summarize the number of chunks and bytes passed

Awesome Lists containing this project

README

          

# stream-conclusion
Analyses streams to summarize the number of chunks and bytes passed

The given callback will be called when the stream ends, and provides an argument with the properties `chunks` and `bytes`.

Example:
```js
var streamConclusion = require('stream-conclusion');

function conclusion(result) {
console.log(result.bytes + " bytes passed through in " + result.chunks + " chunks");
}

inStream.pipe(streamConclusion(conclusion)).pipe(outStream);
```