Interface IAbortAblePromiseBase<T>

a promise like object that has an abort method

interface IAbortAblePromiseBase<T> {
    abort(): void;
    isAborted(): boolean;
    then<TResult1 = T, TResult2 = never>(
        onfulfilled?: null | (value: T) => TResult1 | PromiseLike<TResult1>,
        onrejected?: null | (reason: unknown) => TResult2 | PromiseLike<TResult2>,
    ): IAbortAblePromiseBase<TResult1 | TResult2>;
}

Type Parameters

  • T

Hierarchy

  • PromiseLike<T>
    • IAbortAblePromiseBase

Methods

  • whether this promise was aborted

    Returns boolean