6 lines
113 B
TypeScript
6 lines
113 B
TypeScript
|
export type Cancel = () => void;
|
||
|
export type Source<T> = {
|
||
|
(): T;
|
||
|
(callback: (value: T) => void): Cancel;
|
||
|
};
|