Skip to content

Commit

Permalink
docs: ReduceStream 문서 작성
Browse files Browse the repository at this point in the history
  • Loading branch information
daengdaengLee committed Aug 21, 2023
1 parent b22b7f3 commit 7516044
Showing 1 changed file with 17 additions and 0 deletions.
17 changes: 17 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -46,6 +46,23 @@ await pipeline(
);
```

### ReduceStream

Accumulate the input data into the acc object.

```typescript
import { ReduceStream } from "utilitystreams";

await pipeline(
arguments,
new ReduceStream(
{ acc: "", f: (acc, cur) => `${acc} ${cur}` },
{ objectMode: true },
),
process.stdout,
);
```

### ToArrayStream

Collects the input data into an array.
Expand Down

0 comments on commit 7516044

Please sign in to comment.