0no-co / wonka

🎩 A tiny but capable push & pull stream library for TypeScript and Flow
MIT License
709 stars 29 forks source link

New sources and operators? (roadmap) #113

Closed mobily closed 1 year ago

mobily commented 2 years ago

hello there! 👋 I have been waiting for the next Wonka release for a long time, and I'm happy to see v6!

Although, I'm a bit concerned about missing new source creators and operators in this specific release. Functions like: combineLatest, forkJoin, makeBehaviorSubject, startWith, endWith, pairwise, distinct, distinctUntilChanged etc. would be really great addition to Wonka, is this something on your roadmap? (I'd be happy to help with implementing a few if you need help)

domeknn commented 2 years ago

Leaving +1. Wonka is fantastic lib 😍 but already missing many operators compared to rxjs :(

kitten commented 2 years ago

I think I could make an argument for some here, but not for all 🤔 It's simply a matter of what the goal is, because wonka's goal isn't to have an operator for everything, but to have enough operators so that it's trivial to implement any of the typical Reactive behaviour, even if that sometimes means combining some operators.

I think there are some here that are too trivial to actually add, namely:

As for distinct, I can see distinct(keySelector) being useful, but I personally never used distinct(keySelector, flush). I think this is a corner case, but I'm not too eager to add it, since I think it is of limited use.

I think an argument can definitely be made for makeBehaviorSubject, combineLatest (which basically would be refactoring combine in my opinion), and forkJoin (which then becomes a derivative of combineLatest basically). But I'm not 100% sure about all of them.

kitten commented 1 year ago

Closing for now, since this isn't really actionable just yet until more operators are needed or planned ✌️