Skip to content

Instantly share code, notes, and snippets.

@GarryBrown
Created June 18, 2020 10:53
Show Gist options
  • Save GarryBrown/eb72af4ec06f9d0b8e387dd6c8173b5e to your computer and use it in GitHub Desktop.
Save GarryBrown/eb72af4ec06f9d0b8e387dd6c8173b5e to your computer and use it in GitHub Desktop.
class Observable<T> implements Subscribable<T> {
...
constructor(subscribe?: (this: Observable<T>, subscriber: Subscriber<T>) => TeardownLogic) {
if (subscribe) {
this._subscribe = subscribe;
}
}
}
...
type TeardownLogic = Unsubscribable | Function | void;
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment