Rxjs - Operators - Concat

Signature

export declare function concat<T, R>(...observables: Array<ObservableInput<any> | Scheduler>): Observable<R>;

接受多个流- 根据顺序连接,连接的前提是前面的流complete了后面的才会开始

var timer1 = Rx.Observable.interval(1000).take(10);
var timer2 = Rx.Observable.interval(2000).take(6);
var timer3 = Rx.Observable.interval(500).take(10);
var result = Rx.Observable.concat(timer1, timer2, timer3);
result.subscribe(x => console.log(x));