Last change
on this file since fa375fe was 6a3a178, checked in by Ema <ema_spirova@…>, 3 years ago |
initial commit
|
-
Property mode
set to
100644
|
File size:
517 bytes
|
Line | |
---|
1 | "use strict";
|
---|
2 | Object.defineProperty(exports, "__esModule", { value: true });
|
---|
3 | var observable_1 = require("../symbol/observable");
|
---|
4 | exports.subscribeToObservable = function (obj) { return function (subscriber) {
|
---|
5 | var obs = obj[observable_1.observable]();
|
---|
6 | if (typeof obs.subscribe !== 'function') {
|
---|
7 | throw new TypeError('Provided object does not correctly implement Symbol.observable');
|
---|
8 | }
|
---|
9 | else {
|
---|
10 | return obs.subscribe(subscriber);
|
---|
11 | }
|
---|
12 | }; };
|
---|
13 | //# sourceMappingURL=subscribeToObservable.js.map |
---|
Note:
See
TracBrowser
for help on using the repository browser.