Runs two observable sequences in parallel and combines their last elements.
second
(Observable
): Second observable sequence.resultSelector
(Any
): The default value if no such element exists. If not specified, defaults to null.
(Observable
): An observable sequence that contains elements from the input sequence that satisfy the condition.
var source1 = Rx.Observable.return(42);
var source2 = Rx.Observable.range(0, 3);
var source = source1.forkJoin(source2, function (s1, s2) {
return s1 + s2;
});
var subscription = source.subscribe(
function (x) {
console.log('Next: ' + x);
},
function (err) {
console.log('Error: ' + err);
},
function () {
console.log('Completed');
});
// => Next: 45
// => Completed
File:
Dist:
Prerequisites:
NPM Packages:
NuGet Packages:
Unit Tests: