combine_latest emit_on behavior
See original GitHub issueShould we buffer the combine_latest
emit_on
stream?
Context
Consider the following situation, we have two streams a
and b
. We are going to use combine_latest
to combine them, with an emit only on a
. 5 entries come down from a
then one comes down from b
then one from a
. Due to the lack of data from b
none of the 5 initial a
entries have been emitted since the b
was missing. Now that we have b
data do we expect it to emit 6 times (which would require the buffering of the emit_on
stream or only once (which may violate the idea of the emit_on
stream always emitting)?
Issue Analytics
- State:
- Created 6 years ago
- Comments:26 (20 by maintainers)
Top Results From Across the Web
combineLatest behaviour in Rxjs 5? - Stack Overflow
Combines multiple Observables to create an Observable whose values are calculated from the latest values of each of its input Observables. or.
Read more >combineLatest - Learn RxJS
This operator is best used when you have multiple, long-lived observables that rely on each other for some calculation or determination.
Read more >RxJS - combineLatest vs merge Explained - BansoCode
merge and combineLatest operators are occasionally compared with each other. They both trigger an emission if one of their inner Observables ...
Read more >CombineLatest operator - ReactiveX
The CombineLatest operator behaves in a similar way to Zip, but while Zip emits items only when each of the zipped source Observables...
Read more >All you need to know about combineLatest operator in RxJS
Combines multiple Observable to create an Observable whose values are calculated from the latest values of each of its input Observables.
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
zip_product
works for me. I have a version of this already in the heterogeneous sibling library: https://github.com/xpdAcq/SHED/pull/34/files#diff-65d9b3aec4fc1da045d510c0bf1badf7R979 (I can change the name, but it seems to do the job. Relevant tests: https://github.com/xpdAcq/SHED/pull/34/files#diff-dfb8639c0c54113885f051bbf83937ccR640)Also keen to have a
zip_longest
as you mentioned above, I can see that this could definitely be useful is some case.What about
zip_product
as a name?Edit: Nevermind I was thinking it did more of a product-like combination. I’m not 100% sure what your stream above ^^ is doing Edit2: Yep,
zip_latest
seems appropriate