Skip to content

Interface: RenderingOptions<G>

Rendering control options

Since

v0.27.0

Signature

ts
export interface RenderingOptions<G extends GunshiParamsConstraint = DefaultGunshiParams>

Type Parameters

NameDescription
G extends GunshiParamsConstraint = DefaultGunshiParamsA type extending GunshiParams to specify the shape of render options.

Properties

NameTypeDescription
header (optional)((ctx: Readonly<CommandContext<G>>) => Promise<string>) | nullHeader rendering configuration - null: Disable rendering - function: Use custom renderer - undefined (when omitted): Use default renderer
usage (optional)((ctx: Readonly<CommandContext<G>>) => Promise<string>) | nullUsage rendering configuration - null: Disable rendering - function: Use custom renderer - undefined (when omitted): Use default renderer
validationErrors (optional)((ctx: Readonly<CommandContext<G>>, error: AggregateError) => Promise<string>) | nullValidation errors rendering configuration - null: Disable rendering - function: Use custom renderer - undefined (when omitted): Use default renderer

Released under the MIT License.