Variable runConst
run: <const E extends object, const S extends object, const SS extends object>(
data: InferRootOptionsArguments<E> & InferSubCommandOptionsArguments<S> & InferSubSubCommandOptionsArguments<
SS,
> & NoInfer<
(
ParseData & (E & Simplify<{ [K in keyof S]: K extends keyof SS ? Simplify<{ [K in keyof S[K]]: K extends keyof SS[K] ? Simplify<{ [K in keyof S[K][K]]: K extends keyof SS[K][K] ? Simplify<...> : S[K][K][K]; } & { [K in keyof SS[K][K] as K extends keyof S[K][K] ? never : K]: SS[K][K][K]; }> : S[K][K]; } & { [K in key...
) & (
(
E & Simplify<
{
[K in string
| number
| symbol]: K extends keyof (...) ? Simplify<(...)> : (...)[(...)]
} & {
[K in string
| number
| symbol as K extends keyof (...) ? never : K]: SS[K]
},
>
) extends { subCommands: {} }
? { subCommands: SanitizeSubCommandOptArgs<O["subCommands"]> }
: {}
) & MainDeclarations<
E & Simplify<
{
[K in string
| number
| symbol]: K extends keyof (...) ? Simplify<(...)> : (...)[(...)]
} & {
[K in string
| number
| symbol as K extends keyof (...) ? never : K]: SS[K]
},
>,
null,
[
E & Simplify<
{
[K in (...)
| (...)
| (...)]: (...) extends (...) ? (...) : (...)
} & {
[K in (...)
| (...)
| (...) as (...) extends (...) ? (...) : (...)]: (...)[(...)]
},
>,
],
>,
>,
options?: { argv?: string[] },
) => { global: Promise<GlobalData<E & S>>; onDone?: () => void } = runCli
data: InferRootOptionsArguments<E> & InferSubCommandOptionsArguments<S> & InferSubSubCommandOptionsArguments<
SS,
> & NoInfer<
(
ParseData & (E & Simplify<{ [K in keyof S]: K extends keyof SS ? Simplify<{ [K in keyof S[K]]: K extends keyof SS[K] ? Simplify<{ [K in keyof S[K][K]]: K extends keyof SS[K][K] ? Simplify<...> : S[K][K][K]; } & { [K in keyof SS[K][K] as K extends keyof S[K][K] ? never : K]: SS[K][K][K]; }> : S[K][K]; } & { [K in key...
) & (
(
E & Simplify<
{
[K in string
| number
| symbol]: K extends keyof (...) ? Simplify<(...)> : (...)[(...)]
} & {
[K in string
| number
| symbol as K extends keyof (...) ? never : K]: SS[K]
},
>
) extends { subCommands: {} }
? { subCommands: SanitizeSubCommandOptArgs<O["subCommands"]> }
: {}
) & MainDeclarations<
E & Simplify<
{
[K in string
| number
| symbol]: K extends keyof (...) ? Simplify<(...)> : (...)[(...)]
} & {
[K in string
| number
| symbol as K extends keyof (...) ? never : K]: SS[K]
},
>,
null,
[
E & Simplify<
{
[K in (...)
| (...)
| (...)]: (...) extends (...) ? (...) : (...)
} & {
[K in (...)
| (...)
| (...) as (...) extends (...) ? (...) : (...)]: (...)[(...)]
},
>,
],
>,
>,
options?: { argv?: string[] },
) => { global: Promise<GlobalData<E & S>>; onDone?: () => void } = runCli
Type Declaration
- <const E extends object, const S extends object, const SS extends object>(
data: InferRootOptionsArguments<E> & InferSubCommandOptionsArguments<S> & InferSubSubCommandOptionsArguments<
SS,
> & NoInfer<
(
ParseData & (E & Simplify<{ [K in keyof S]: K extends keyof SS ? Simplify<{ [K in keyof S[K]]: K extends keyof SS[K] ? Simplify<{ [K in keyof S[K][K]]: K extends keyof SS[K][K] ? Simplify<...> : S[K][K][K]; } & { [K in keyof SS[K][K] as K extends keyof S[K][K] ? never : K]: SS[K][K][K]; }> : S[K][K]; } & { [K in key...
) & (
(
E & Simplify<
{
[K in string
| number
| symbol]: K extends keyof (...) ? Simplify<(...)> : (...)[(...)]
} & {
[K in string
| number
| symbol as K extends keyof (...) ? never : K]: SS[K]
},
>
) extends { subCommands: {} }
? { subCommands: SanitizeSubCommandOptArgs<O["subCommands"]> }
: {}
) & MainDeclarations<
E & Simplify<
{
[K in string
| number
| symbol]: K extends keyof (...) ? Simplify<(...)> : (...)[(...)]
} & {
[K in string
| number
| symbol as K extends keyof (...) ? never : K]: SS[K]
},
>,
null,
[
E & Simplify<
{
[K in (...)
| (...)
| (...)]: (...) extends (...) ? (...) : (...)
} & {
[K in (...)
| (...)
| (...) as (...) extends (...) ? (...) : (...)]: (...)[(...)]
},
>,
],
>,
>,
options?: { argv?: string[] },
): { global: Promise<GlobalData<E & S>>; onDone?: () => void } Type Parameters
- const E extends object
- const S extends object
- const SS extends object
Parameters
- data: InferRootOptionsArguments<E> & InferSubCommandOptionsArguments<S> & InferSubSubCommandOptionsArguments<
SS,
> & NoInfer<
(
ParseData & (E & Simplify<{ [K in keyof S]: K extends keyof SS ? Simplify<{ [K in keyof S[K]]: K extends keyof SS[K] ? Simplify<{ [K in keyof S[K][K]]: K extends keyof SS[K][K] ? Simplify<...> : S[K][K][K]; } & { [K in keyof SS[K][K] as K extends keyof S[K][K] ? never : K]: SS[K][K][K]; }> : S[K][K]; } & { [K in key...
) & (
(
E & Simplify<
{
[K in string
| number
| symbol]: K extends keyof (...) ? Simplify<(...)> : (...)[(...)]
} & {
[K in string
| number
| symbol as K extends keyof (...) ? never : K]: SS[K]
},
>
) extends { subCommands: {} }
? { subCommands: SanitizeSubCommandOptArgs<O["subCommands"]> }
: {}
) & MainDeclarations<
E & Simplify<
{
[K in string
| number
| symbol]: K extends keyof (...) ? Simplify<(...)> : (...)[(...)]
} & {
[K in string
| number
| symbol as K extends keyof (...) ? never : K]: SS[K]
},
>,
null,
[
E & Simplify<
{ [K in (...)
| (...)
| (...)]: (...) extends (...) ? (...) : (...) } & {
[K in (...) | (...) | (...) as (...) extends (...) ? (...) : (...)]: (
...
)[(...)]
},
>,
],
>,
>Command configuration
- options: { argv?: string[] } = {}
Options for the run
- argv: Override arguments. (defaults to process.argv.slice(2))
Returns { global: Promise<GlobalData<E & S>>; onDone?: () => void }
- <const E extends object, const S extends object, const SS extends object>(
Run a command line application