checksum-stream is a passthrough stream that calculates the digest and size for data piped through it. Before closing, it will emit
size events with the final stream size.
It can also be configured to error if
size do not matched a passed-in value that is expected for either or both.
size errors will always be emitted first.
$ npm install --save checksum-stream
const checksumStream =const fs =const request =let req = requestreq