MCPcopy Create free account
hub / github.com/webpack/webpack-cli / CommandOptions

Interface CommandOptions

packages/webpack-cli/src/webpack-cli.ts:118–138  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

116}
117
118interface CommandOptions<
119 A = void,
120 O extends CommanderArgs = CommanderArgs,
121 C extends Context = Context,
122> extends CommanderCommandOptions {
123 rawName: string;
124 name: string;
125 alias: string | string[];
126 description?: string;
127 usage?: string;
128 dependencies?: string[];
129 pkg?: string;
130 preload?: () => Promise<C>;
131 options?:
132 | CommandOption[]
133 | ((command: Command & { context: C }) => CommandOption[])
134 | ((command: Command & { context: C }) => Promise<CommandOption[]>);
135 action: A extends void
136 ? (options: O, cmd: Command & { context: C }) => void | Promise<void>
137 : (args: A, options: O, cmd: Command & { context: C }) => void | Promise<void>;
138}
139
140interface WebpackContext {
141 webpack: typeof webpack;

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected