Skip to content

Latest commit

 

History

History
63 lines (49 loc) · 2.26 KB

ziparray.md

File metadata and controls

63 lines (49 loc) · 2.26 KB

Rx.Observable.zipArray(...args)

Merges the specified observable sequences into one observable sequence by emitting a list with the elements of the observable sequences at corresponding indexes.

Arguments

  1. args (Arguments | Array): Observable sources.

Returns

(Observable): An observable sequence containing lists of elements at corresponding indexes.

Example

var range = Rx.Observable.range(0, 5);

var source = Rx.Observable.zipArray(
    range,
    range.skip(1), 
    range.skip(2)
);

var subscription = source.subscribe(
    function (x) {
        console.log('Next: ' + x);
    },
    function (err) {
        console.log('Error: ' + err);   
    },
    function () {
        console.log('Completed');   
    });

// => Next: 0,1,2 
// => Next: 1,2,3 
// => Next: 2,3,4 
// => Completed

Location

File:

Dist:

Prerequisites:

NPM Packages:

NuGet Packages:

Unit Tests: