flyd
flyd copied to clipboard
Support multiple operators for Pipe
Hi — brilliant library
Simple question: I would like to do the following:
mystream
.pipe(
flyd.filter(value => value !== 'foo'),
flyd.skip(1),
flyd.dropRepeats()
)
.map((value) => {
console.log(value);
});
Instead of
mystream
.pipe(flyd.filter(value => value !== 'foo'))
.pipe(flyd.skip(1))
.pipe(flyd.dropRepeats())
.map((value) => {
console.log(value);
});
Basically to avoid repeating .pipe
as it is much cleaner.
I've seen some discussion here: https://github.com/paldepind/flyd/issues/137
I'm assuming this pattern for pipe is somehow contrary to the design of flyd?
Thanks