forkJoin
creates an Observable from multiple Observables.
Resulting stream waits for all input streams to complete, then combines and emits their latest values
123456789101112131415const { rxObserver } = require('api/v0.3'); const { timer, forkJoin } = require('rxjs'); const { mapTo, take } = require('rxjs/operators'); const a$ = timer(10).pipe(mapTo('a')); const b$ = timer(5, 5).pipe(take(3)); const result$ = forkJoin([ a$, b$ ]); a$.subscribe(rxObserver('a$')); b$.subscribe(rxObserver('b$')); result$.subscribe(rxObserver('forkJoin(a$, b$)'));