source: trip-planner-front/node_modules/rxjs/_esm2015/internal/util/subscribeToObservable.js@ 571e0df

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

initial commit

  • Property mode set to 100644
File size: 437 bytes
Line 
1import { observable as Symbol_observable } from '../symbol/observable';
2export const subscribeToObservable = (obj) => (subscriber) => {
3 const obs = obj[Symbol_observable]();
4 if (typeof obs.subscribe !== 'function') {
5 throw new TypeError('Provided object does not correctly implement Symbol.observable');
6 }
7 else {
8 return obs.subscribe(subscriber);
9 }
10};
11//# sourceMappingURL=subscribeToObservable.js.map
Note: See TracBrowser for help on using the repository browser.