Package Exports
- @jorgeferrero/stream-to-buffer
This package does not declare an exports field, so the exports above have been automatically detected and optimized by JSPM instead. If any package subpath is missing, it is recommended to post an issue to the original package (@jorgeferrero/stream-to-buffer) to support the "exports" field. If that is not possible, create a JSPM override to customize the exports field for this package.
Readme
Stream To Buffer
A promise based Node.js package that converts a Node.js Readable to buffer
Installation
npm i @jorgeferrero/stream-to-buffer
Usage
import { streamToBuffer } from '@jorgeferrero/stream-to-buffer';
import * as fs from 'fs';
const data = await streamToBuffer(fs.createReadStream('./file'));
console.log(data.toString());
Output should be the the content of the file
Test
npm run test