AbortController.d.ts 540 字节
Newer Older
lwplvx's avatar
add app  
lwplvx 已提交
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
/** @private */
export declare class AbortController implements AbortSignal {
    private isAborted;
    onabort: (() => void) | null;
    abort(): void;
    readonly signal: AbortSignal;
    readonly aborted: boolean;
}
/** Represents a signal that can be monitored to determine if a request has been aborted. */
export interface AbortSignal {
    /** Indicates if the request has been aborted. */
    aborted: boolean;
    /** Set this to a handler that will be invoked when the request is aborted. */
    onabort: (() => void) | null;
}