-
Notifications
You must be signed in to change notification settings - Fork 2
Open
Milestone
Description
In the spirit of being more like Underscore, chaining should be optional syntax. Understream functions should stand alone, taking a (Readable) stream as an explicit first argument.
Chaining can be a clunky syntax when only one or two transformations will be applied. Furthermore, it implies that pipelines should be linear, which does not necessarily gel with the actual operations (like join or its inverse, partition).
For example, instead of writing this:
_.stream(stream).map(some_fun).stream()
I should be able to write:
_.map stream, some_fun
and get back a Readable stream in which some_fun is applied to each chunk.
Since this creates a name clash, I think mixing into Underscore should be dropped in favor of a new Understream variable. Some ideas: _s, us, understream, _stream.
Metadata
Metadata
Assignees
Labels
No labels