SelectOpts
Defined in: packages/prompt/dist/index.d.mts:52
Options for select input.
Extends
Section titled “Extends”CoreOpts<T>
Extended by
Section titled “Extended by”Type Parameters
Section titled “Type Parameters”T
M extends boolean = false
Properties
Section titled “Properties”clearPromptOnDone?
Section titled “clearPromptOnDone?”
optionalclearPromptOnDone?:boolean
Defined in: packages/prompt/dist/core/index.d.mts:80
If the screen should be cleared when finishing a prompt.
Inherited from
Section titled “Inherited from”default?
Section titled “default?”
optionaldefault?:T
Defined in: packages/prompt/dist/core/index.d.mts:68
The default value.
Inherited from
Section titled “Inherited from”initialIndex?
Section titled “initialIndex?”
optionalinitialIndex?:number
Defined in: packages/prompt/dist/index.d.mts:64
The initial option selected.
input?
Section titled “input?”
optionalinput?:ReadStream
Defined in: packages/prompt/dist/core/index.d.mts:72
The standard input. Defaults to process.stdin.
Inherited from
Section titled “Inherited from”message
Section titled “message”message:
string
Defined in: packages/prompt/dist/core/index.d.mts:56
The message of the prompt.
Inherited from
Section titled “Inherited from”multiple?
Section titled “multiple?”
optionalmultiple?:M
Defined in: packages/prompt/dist/index.d.mts:60
If the user can select multiple options.
options
Section titled “options”options:
SelectOption<T>[]
Defined in: packages/prompt/dist/index.d.mts:56
Every option the user can pick from.
output?
Section titled “output?”
optionaloutput?:WriteStream
Defined in: packages/prompt/dist/core/index.d.mts:76
The standard output. Defaults to process.stdout.
Inherited from
Section titled “Inherited from”signal?
Section titled “signal?”
optionalsignal?:AbortSignal
Defined in: packages/prompt/dist/core/index.d.mts:84
An AbortSignal to cancel the prompt.
Inherited from
Section titled “Inherited from”theme?
Section titled “theme?”
optionaltheme?:Theme
Defined in: packages/prompt/dist/core/index.d.mts:64
The theme of the prompt.
Inherited from
Section titled “Inherited from”validate?
Section titled “validate?”
optionalvalidate?:StandardSchemaV1<any,T> | ((value) =>boolean|T)
Defined in: packages/prompt/dist/core/index.d.mts:60
A validator function, or a Standard Schema validator.