Skip to main content
Using Deno in production at your company? Earn free Deno merch.
Give us feedback
Module

x/timeout/deps/abortable.ts>Abortable

Abortable promise timeout for Deno
Latest
class Abortable
implements Abortable<T>
import { Abortable } from "https://deno.land/x/timeout@2.4/deps/abortable.ts";

Constructors

new
Abortable(promise: Promise<T>, aborter: AbortController)

Properties

readonly
[Symbol.toStringTag]

Methods

catch<TError = never>(onrejected?: ((reason: any) => TError | PromiseLike<TError>) | null)
finally(onfinally?: (() => void) | null)
then<TResult = T, TError = never>(onfullfilled?: ((value: T) => TResult | PromiseLike<TResult>) | null, onrejected?: ((reason: any) => TError | PromiseLike<TError>) | null)
interface Abortable
implements Promise<T>
import { type Abortable } from "https://deno.land/x/timeout@2.4/deps/abortable.ts";

Properties

readonly
promise: Promise<T>
readonly
aborter: AbortController

Methods

abort(): void
then<TResult = T, TError = never>(onfullfilled?: ((value: T) => TResult | PromiseLike<TResult>) | null, onrejected?: ((reason: any) => TError | PromiseLike<TError>) | null): Abortable<TResult | TError>
catch<TError = never>(onrejected?: ((reason: any) => TError | PromiseLike<TError>) | null): Abortable<TError>
finally(onfinally?: (() => void) | null): Abortable<T>