Skip to content

Latest commit

 

History

History
47 lines (27 loc) · 1.49 KB

ConfigureErrorHandlingEpilogue.md

File metadata and controls

47 lines (27 loc) · 1.49 KB

@black-flag/coreDocs


@black-flag/core / index / ConfigureErrorHandlingEpilogue

Type Alias: ConfigureErrorHandlingEpilogue()<CustomContext>

ConfigureErrorHandlingEpilogue<CustomContext>: (meta, argv, context) => Promisable<void>

This function is called once at the very end of the error handling process after an error has occurred.

Note that this function is always called whenever there is an error, regardless of which other functions have already been called. The only exceptions to this are if (1) the error occurs within configureErrorHandlingEpilogue itself or (2) the error is an instance of GracefulEarlyExitError.

This function is also called even after yargs internally handles and reports an argument parsing/validation error.

Type Parameters

CustomContext extends ExecutionContext = ExecutionContext

Parameters

meta

meta.error: unknown

meta.exitCode: number

meta.message: string

argv: Omit<Partial<Arguments>, typeof $executionContext> & object

context: CustomContext

Returns

Promisable<void>

Defined in

types/configure.ts:81