Interface: RouteMapBuilderArguments<R, CONTEXT>
Type Parameters
• R extends string
• CONTEXT extends CommandContext
Properties
aliases?
readonly
optional
aliases:Readonly
<Record
<Exclude
<string
,R
>,R
>>
If specified, aliases can be used instead of the original route name to resolve to a given route.
Defined in
packages/core/src/routing/route-map/builder.ts:39
defaultCommand?
readonly
optional
defaultCommand:NoInfer
<R
>
When the command line inputs navigate directly to a route map, the default behavior is to print the help text.
If this value is present, the command at the specified route will be run instead. This means that otherwise invalid routes will not throw an error and will be considered as arguments/flags to that command.
The type checking for this property requires it must be a valid route, but it does not type check that this route points to a command.
If this value is a route for a route map instead of a command, that is invalid and buildRouteMap
will throw an error.
Defined in
packages/core/src/routing/route-map/builder.ts:31
docs
readonly
docs:RouteMapDocumentation
<R
>
Help documentation for route map.
Defined in
packages/core/src/routing/route-map/builder.ts:35
routes
readonly
routes:Readonly
<Record
<R
,RoutingTarget
<CONTEXT
>>>
Mapping of names to routing targets (commands or other route maps). Must contain at least one route to be a valid route map.