<commit_before>Stream-Promise
==========

Stream-Promise is a tiny nodejs stream to Promise converter module, and that's pretty much it.

#### API
```js
class StreamPromise {
  static create(Stream):Promise<string>
}
```

#### Example
```js
const StreamPromise = require('sb-stream-promise')
const FS = require('fs')
StreamPromise.create(FS.createReadStream(`/etc/passwd`))
  .then(function(contents) {
    console.log(contents)<commit_msg>:memo: Update README<commit_after>Stream-Promise
==========

Stream-Promise is a Node.js stream to Promise conversion module.

#### Installation

```
npm install --save sb-stream-promise
```

#### API

```js
export default function createdefaultPromise(stream: Stream, bytesLimit: ?number)
```

#### Example
```js
const FS = require('fs')
const createStreamPromise = require('sb-stream-promise')

createStreamPromise(FS.createReadStream(`/etc/passwd`))
  .then(function(contents) {
    console.log(contents)
  })
  .catch(function(error) {
    console.error('unable to read file', error)
{'fraction_non_alphanumeric': 0.1655306718597858, 'fraction_numerical': 0.0, 'mean_word_length': 5.589743589743589, 'pattern_counts': {'":': 0, '<': 4, '<?xml version=': 0, '>': 4, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '2667893', 'n_tokens_mistral': 323, 'n_tokens_neox': 306, 'n_words': 75}