stream-to-blob travis npm downloads javascript style guide
This package converts a Readable Stream into a Blob.
This package is used by WebTorrent.
npm install stream-to-blob
const streamToBlob = require('stream-to-blob') const stream = new stream.Readable() // any Node.js readable stream const blob = await streamToBlob(stream)
Convert the given readable stream, stream, into a W3C Blob. If mimeType is provided, then the Blob will have its mime type set to that value.
Returns a Promise which resolves to a Blob object on success. Otherwise, rejects with an Error.
MIT. Copyright (c) Feross Aboukhadijeh.