Module

x/cliffy/prompt.ts>Toggle

Command line framework for deno 🦕 Including Commandline-Interfaces, Prompts, CLI-Table, Arguments Parser and more...
Extremely Popular
Go to Latest
class Toggle
extends GenericInput<boolean, ToggleSettings>
import { Toggle } from "https://dotland.deno.dev/x/cliffy@v0.6.1/prompt.ts";

Methods

protected
format(value: boolean): string
protected
handleEvent(event: KeyEvent): Promise<boolean>
protected
read(): Promise<boolean>
protected
selectActive()
protected
selectInactive()
protected
setPrompt(message: string)
protected
transform(value: string): boolean | undefined
protected
validate(value: string): boolean

Static Methods

prompt(options: string | ToggleOptions): Promise<boolean | undefined>