|
|
%!s(int64=4) %!d(string=hai) anos | |
|---|---|---|
| src | %!s(int64=4) %!d(string=hai) anos | |
| .gitignore | %!s(int64=5) %!d(string=hai) anos | |
| .prettierrc | %!s(int64=5) %!d(string=hai) anos | |
| package.json | %!s(int64=5) %!d(string=hai) anos | |
| readme.md | %!s(int64=4) %!d(string=hai) anos | |
| tsconfig.json | %!s(int64=5) %!d(string=hai) anos |
$PROJECT_NAME is a user friendly, type safe, wrapper around node streams. The API is a simplified version of scala's akka stream.
Node stream API has a few flaws in my view. It is tedious, verbose, error prone, badly typed... Yet, it does work. So stream-helper wraps node stream and provides a user friendly API on top of it, along with some useful functional helpers (filter, map...). This allows stream-helper to easily integrate with existing node streams, while providing simplercorrecly typed and fluent API.
Source.fromReadableBuilder
The API is organised around three interfaces :
TODO : lazy evaluation
This is the starting point of your stream. Think of it as a Readable in node streams.
As a matter of fact, you can build a source from a Readable with Source.fromReadableBuilder.