Type alias Observable<T>

Observable<T>: {
    [observable](): Observable<T>;
    subscribe(observer): {
        unsubscribe: Unsubscribe;
    };
}

A minimal observable of state changes. For more information, see the observable proposal: https://github.com/tc39/proposal-observable

Type Parameters

  • T

Type declaration

  • [observable]:function
  • subscribe:function
    • The minimal observable subscription method.

      Parameters

      • observer: Observer<T>

        Any object that can be used as an observer. The observer object should have a next method.

      Returns {
          unsubscribe: Unsubscribe;
      }

      An object with an unsubscribe method that can be used to unsubscribe the observable from the store, and prevent further emission of values from the observable.