Sha256: a54630b9f6319dce14b89eb0d8c02797af5842af04b66c8ff7032d29f9c568ba

Contents?: true

Size: 720 Bytes

Versions: 49

Compression:

Stored size: 720 Bytes

Contents

import { Observable } from '../Observable';
import { repeat as higherOrder } from '../operators/repeat';

/**
 * Returns an Observable that repeats the stream of items emitted by the source Observable at most count times.
 *
 * <img src="./img/repeat.png" width="100%">
 *
 * @param {number} [count] The number of times the source Observable items are repeated, a count of 0 will yield
 * an empty Observable.
 * @return {Observable} An Observable that repeats the stream of items emitted by the source Observable at most
 * count times.
 * @method repeat
 * @owner Observable
 */
export function repeat<T>(this: Observable<T>, count: number = -1): Observable<T> {
  return higherOrder(count)(this) as Observable<T>;
}

Version data entries

49 entries across 49 versions & 4 rubygems

Version Path
ilog-0.4.1 node_modules/rxjs/src/operator/repeat.ts
ilog-0.4.0 node_modules/rxjs/src/operator/repeat.ts
ilog-0.3.3 node_modules/rxjs/src/operator/repeat.ts
govuk_publishing_components-18.0.0 node_modules/rxjs/src/operator/repeat.ts
govuk_publishing_components-17.21.0 node_modules/rxjs/src/operator/repeat.ts
govuk_publishing_components-17.20.0 node_modules/rxjs/src/operator/repeat.ts
govuk_publishing_components-17.19.1 node_modules/rxjs/src/operator/repeat.ts
govuk_publishing_components-17.19.0 node_modules/rxjs/src/operator/repeat.ts
govuk_publishing_components-17.18.0 node_modules/rxjs/src/operator/repeat.ts
govuk_publishing_components-17.17.0 node_modules/rxjs/src/operator/repeat.ts
govuk_publishing_components-17.16.0 node_modules/rxjs/src/operator/repeat.ts
govuk_publishing_components-17.15.0 node_modules/rxjs/src/operator/repeat.ts
govuk_publishing_components-17.14.0 node_modules/rxjs/src/operator/repeat.ts
govuk_publishing_components-17.13.0 node_modules/rxjs/src/operator/repeat.ts
govuk_publishing_components-17.12.2 node_modules/rxjs/src/operator/repeat.ts
govuk_publishing_components-17.12.1 node_modules/rxjs/src/operator/repeat.ts
govuk_publishing_components-17.12.0 node_modules/rxjs/src/operator/repeat.ts
govuk_publishing_components-17.11.0 node_modules/rxjs/src/operator/repeat.ts
govuk_publishing_components-17.10.0 node_modules/rxjs/src/operator/repeat.ts
govuk_publishing_components-17.9.0 node_modules/rxjs/src/operator/repeat.ts