-
-
Save huang47/c61c8a3f3d3336f9d0ee 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
var Rx = require('rx'); | |
var s1 = new Rx.Subject(); | |
var s2 = new Rx.Subject(); | |
var s3 = new Rx.Subject(); | |
Rx.Observable.merge(s1, s2, s3). | |
forEach( | |
console.log.bind(console, 'next'), | |
console.log.bind(console, 'error'), | |
console.log.bind(console, 'complete') | |
); | |
s1.onNext(1); | |
s2.onCompleted(1); | |
s3.onCompleted(1); | |
s1.onCompleted(1); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment