UNPKG

361 BTypeScriptView Raw
1export interface ILazyObservable<T> {
2 current(): T;
3 refresh(): T;
4 reset(): T;
5 pending: boolean;
6}
7export declare function lazyObservable<T>(fetch: (sink: (newValue: T) => void) => void): ILazyObservable<T | undefined>;
8export declare function lazyObservable<T>(fetch: (sink: (newValue: T) => void) => void, initialValue: T): ILazyObservable<T>;