This commit is contained in:
手瓜一十雪
2025-01-04 13:03:29 +08:00
parent c2c1f7b6d4
commit beac221dc6

View File

@@ -1,4 +1,4 @@
type TaskExecutor<T> = (resolve: (value: T | PromiseLike<T>) => void, reject: (reason?: any) => void, onCancel: (callback: () => void) => void) => void;
export type TaskExecutor<T> = (resolve: (value: T | PromiseLike<T>) => void, reject: (reason?: any) => void, onCancel: (callback: () => void) => void) => void;
export class CancelableTask<T> {
private promise: Promise<T>;