Question from the Introduction to RxJS test

Explain the difference between a ReplaySubject and a BehaviorSubject in RxJS

Hard

What is the difference between a ReplaySubject and a BehaviorSubject?

Author: Amine BouchamStatus: PublishedQuestion passed 98 times
Edit
0
Community Evaluations
developer avatar
Auteur anonyme
03/09/2024
i've answered second and third checkboxes and i'm not sure how it is Partially correct, BehaviorSubject has to have an initial value and ReplaySubject does not emit only once it's full
developer avatar
Auteur anonyme
06/09/2024
The first answer about the ReplayBuffer is left unchecked by most people but should be checked.
developer avatar
Auteur anonyme
06/09/2024
because it's not correct, ReplaySubject doesn't emit only when it's full, if its size is 6 and it received only 3 values then it's been subscribed to it will emit the 3 values, it will not wait till it has 6 values, not sure if i misunderstood the question!