source: trip-planner-front/node_modules/rxjs/_esm2015/internal/scheduled/scheduleObservable.js

Last change on this file was 6a3a178, checked in by Ema <ema_spirova@…>, 3 years ago

initial commit

  • Property mode set to 100644
File size: 824 bytes
RevLine 
[6a3a178]1import { Observable } from '../Observable';
2import { Subscription } from '../Subscription';
3import { observable as Symbol_observable } from '../symbol/observable';
4export function scheduleObservable(input, scheduler) {
5 return new Observable(subscriber => {
6 const sub = new Subscription();
7 sub.add(scheduler.schedule(() => {
8 const observable = input[Symbol_observable]();
9 sub.add(observable.subscribe({
10 next(value) { sub.add(scheduler.schedule(() => subscriber.next(value))); },
11 error(err) { sub.add(scheduler.schedule(() => subscriber.error(err))); },
12 complete() { sub.add(scheduler.schedule(() => subscriber.complete())); },
13 }));
14 }));
15 return sub;
16 });
17}
18//# sourceMappingURL=scheduleObservable.js.map
Note: See TracBrowser for help on using the repository browser.