tryError Documentation

Interface: TryAsyncOptions
Interface

Defined in: [async.ts:13](https://github.com/oconnorjohnson/try-error/blob/e3ae0308069a4fba073f4543d527ad76373db795/src/async.ts#L13) Options for tryAsync function

tryError API Documentation v0.0.1-alpha.1


tryError API Documentation / TryAsyncOptions

Interface: TryAsyncOptions

Defined in: async.ts:13

Options for tryAsync function

Properties

context?

optional context: Record<string, unknown>;

Defined in: async.ts:22

Additional context to include in error


errorType?

optional errorType: string;

Defined in: async.ts:17

Custom error type to use instead of automatic detection


message?

optional message: string;

Defined in: async.ts:27

Custom error message


signal?

optional signal: AbortSignal;

Defined in: async.ts:37

AbortSignal for cancellation (optional)


timeout?

optional timeout: number;

Defined in: async.ts:32

Timeout in milliseconds (optional)