Skip to main content
Deno 2 is finally here 🎉️
Learn more
Module

x/cliffy/packages/prompt/prompts/select.ts>Select

Command line framework for deno 🦕 Including Commandline-Interfaces, Prompts, CLI-Table, Arguments Parser and more...
Extremely Popular
Go to Latest
class Select
extends GenericList<string, string, S>
import { Select } from "https://deno.land/x/cliffy@v0.5.0/packages/prompt/prompts/select.ts";

Type Parameters

S extends SelectSettings

Properties

protected
selected: number

Methods

protected
format(value: string): string
protected
getValue(): string
protected
handleEvent(event: KeyEvent): Promise<boolean>
protected
transform(value: string): string
protected
validate(value: string): boolean
protected
writeListItem(item: SelectOptionSettings, isSelected?: boolean)

Static Methods

protected
mapItem(item: SelectOption): SelectOptionSettings
protected
mapValues(optValues: SelectValueOptions): SelectOption[]
inject(value: string): void
prompt(options: SelectOptions): Promise<string | undefined>