Created
February 19, 2020 15:12
-
-
Save ArtemRomanovsky/8061e061ba9082b9bdfd2ec267f9fce5 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
const observable = Rx.Observable.interval(1000).take(5); | |
const observerA = {...}; | |
const observerB = {...}; | |
const subject = new Rx.Subject(); | |
observable.subscribe(subject); | |
subject.subscribe(observerA); // first execution | |
setTimeout(() => { | |
subject.subscribe(observerB); // the same execution | |
}, 2000); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment