{"action":"created","issue":{"url":"https://api.github.com/repos/ReactiveX/RxJS/issues/1353","repository_url":"https://api.github.com/repos/ReactiveX/RxJS","labels_url":"https://api.github.com/repos/ReactiveX/RxJS/issues/1353/labels{/name}","comments_url":"https://api.github.com/repos/ReactiveX/RxJS/issues/1353/comments","events_url":"https://api.github.com/repos/ReactiveX/RxJS/issues/1353/events","html_url":"https://github.com/ReactiveX/RxJS/issues/1353","id":134056950,"number":1353,"title":"[Question] Extending Observable","user":{"login":"rolandjitsu","id":1479737,"avatar_url":"https://avatars.githubusercontent.com/u/1479737?v=3","gravatar_id":"","url":"https://api.github.com/users/rolandjitsu","html_url":"https://github.com/rolandjitsu","followers_url":"https://api.github.com/users/rolandjitsu/followers","following_url":"https://api.github.com/users/rolandjitsu/following{/other_user}","gists_url":"https://api.github.com/users/rolandjitsu/gists{/gist_id}","starred_url":"https://api.github.com/users/rolandjitsu/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/rolandjitsu/subscriptions","organizations_url":"https://api.github.com/users/rolandjitsu/orgs","repos_url":"https://api.github.com/users/rolandjitsu/repos","events_url":"https://api.github.com/users/rolandjitsu/events{/privacy}","received_events_url":"https://api.github.com/users/rolandjitsu/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":1,"created_at":"2016-02-16T18:20:00Z","updated_at":"2016-02-16T21:13:00Z","closed_at":null,"body":"Do I need to add the `lift()` method if I only want to extend an `Observable` and not add an operator:\r\n```js\r\nimport {Observable} from 'rxjs/Observable';\r\nclass MyOwnObservable extends Observable {\r\n    constructor() {\r\n        super();\r\n    }\r\n    lift(operator) {\r\n\tconst observable = new MyOwnObservable();\r\n\tobservable.source = this;\r\n\tobservable.operator = operator;\r\n\treturn observable;\r\n    }\r\n}\r\n```\r\nOr is it enough to just extend the class:\r\n```js\r\nimport {Observable} from 'rxjs/Observable';\r\nclass MyOwnObservable extends Observable {\r\n    constructor() {\r\n        super();\r\n    }\r\n}\r\n```"},"comment":{"url":"https://api.github.com/repos/ReactiveX/RxJS/issues/comments/184876795","html_url":"https://github.com/ReactiveX/RxJS/issues/1353#issuecomment-184876795","issue_url":"https://api.github.com/repos/ReactiveX/RxJS/issues/1353","id":184876795,"user":{"login":"trxcllnt","id":178183,"avatar_url":"https://avatars.githubusercontent.com/u/178183?v=3","gravatar_id":"","url":"https://api.github.com/users/trxcllnt","html_url":"https://github.com/trxcllnt","followers_url":"https://api.github.com/users/trxcllnt/followers","following_url":"https://api.github.com/users/trxcllnt/following{/other_user}","gists_url":"https://api.github.com/users/trxcllnt/gists{/gist_id}","starred_url":"https://api.github.com/users/trxcllnt/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/trxcllnt/subscriptions","organizations_url":"https://api.github.com/users/trxcllnt/orgs","repos_url":"https://api.github.com/users/trxcllnt/repos","events_url":"https://api.github.com/users/trxcllnt/events{/privacy}","received_events_url":"https://api.github.com/users/trxcllnt/received_events","type":"User","site_admin":false},"created_at":"2016-02-16T21:13:00Z","updated_at":"2016-02-16T21:13:00Z","body":"@rolandjitsu you only need to override `lift` if you want the Observable operators (such as `map`, `filter` etc.) to return instances of _your_ Observable. This is generally most useful when you're extending to augment the Observable type, but it's also useful for other reasons, for example, to decorate Subscribers  for logging or debugging. It's up to you."}}