Skip to content

Commit

Permalink
fix(forkJoin): fix forkJoin typings for forkJoin(Observable<any>[]) (#…
Browse files Browse the repository at this point in the history
  • Loading branch information
benlesh authored Mar 15, 2018
1 parent c611403 commit 17c7f8f
Showing 1 changed file with 11 additions and 2 deletions.
13 changes: 11 additions & 2 deletions src/internal/observable/forkJoin.ts
Original file line number Diff line number Diff line change
Expand Up @@ -8,13 +8,22 @@ import { InnerSubscriber } from '../InnerSubscriber';
import { Subscriber } from '../Subscriber';

/* tslint:disable:max-line-length */
// forkJoin([a$, b$, c$]);
export function forkJoin<T>(sources: [ObservableInput<T>]): Observable<T[]>;
export function forkJoin<T, T2>(sources: [ObservableInput<T>, ObservableInput<T2>]): Observable<[T, T2]>;
export function forkJoin<T, T2, T3>(sources: [ObservableInput<T>, ObservableInput<T2>, ObservableInput<T3>]): Observable<[T, T2, T3]>;
export function forkJoin<T, T2, T3, T4>(sources: [ObservableInput<T>, ObservableInput<T2>, ObservableInput<T3>, ObservableInput<T4>]): Observable<[T, T2, T3, T4]>;
export function forkJoin<T, T2, T3, T4, T5>(sources: [ObservableInput<T>, ObservableInput<T2>, ObservableInput<T3>, ObservableInput<T4>, ObservableInput<T5>]): Observable<[T, T2, T3, T4, T5]>;
export function forkJoin<T, T2, T3, T4, T5, T6>(sources: [ObservableInput<T>, ObservableInput<T2>, ObservableInput<T3>, ObservableInput<T4>, ObservableInput<T5>, ObservableInput<T6>]): Observable<[T, T2, T3, T4, T5, T6]>;
export function forkJoin<T>(sources: Array<ObservableInput<T>>): Observable<T[]>;

// forkJoin(a$, b$, c$)
export function forkJoin<T>(v1: ObservableInput<T>): Observable<T[]>;
export function forkJoin<T, T2>(v1: ObservableInput<T>, v2: ObservableInput<T2>): Observable<[T, T2]>;
export function forkJoin<T, T2, T3>(v1: ObservableInput<T>, v2: ObservableInput<T2>, v3: ObservableInput<T3>): Observable<[T, T2, T3]>;
export function forkJoin<T, T2, T3, T4>(v1: ObservableInput<T>, v2: ObservableInput<T2>, v3: ObservableInput<T3>, v4: ObservableInput<T4>): Observable<[T, T2, T3, T4]>;
export function forkJoin<T, T2, T3, T4, T5>(v1: ObservableInput<T>, v2: ObservableInput<T2>, v3: ObservableInput<T3>, v4: ObservableInput<T4>, v5: ObservableInput<T5>): Observable<[T, T2, T3, T4, T5]>;
export function forkJoin<T, T2, T3, T4, T5, T6>(v1: ObservableInput<T>, v2: ObservableInput<T2>, v3: ObservableInput<T3>, v4: ObservableInput<T4>, v5: ObservableInput<T5>, v6: ObservableInput<T6>): Observable<[T, T2, T3, T4, T5, T6]>;
export function forkJoin<T>(v1: ObservableInput<T>): Observable<T[]>;
export function forkJoin<T>(sources: Array<ObservableInput<T>>): Observable<T[]>;
export function forkJoin<T>(...sources: Array<ObservableInput<T>>): Observable<T[]>;
/* tslint:enable:max-line-length */

Expand Down

0 comments on commit 17c7f8f

Please sign in to comment.