Module

x/cliffy/mod.ts>GenericList

Command line framework for deno 🦕 Including Commandline-Interfaces, Prompts, CLI-Table, Arguments Parser and more...
Extremely Popular
Go to Latest
class GenericList
extends GenericPrompt<T, V, S>
Abstract
import { GenericList } from "https://dotland.deno.dev/x/cliffy@v0.16.0/mod.ts";

Generic list prompt representation.

Properties

protected
index: number
protected
selected: number

Methods

protected
body(): string | undefined | Promise<string | undefined>

Render options.

protected
getListHeight(): number

Get options row height.

protected
abstract
getListItem(item: GenericListOptionSettings, isSelected?: boolean): string

Render option.

protected
getOptionByValue(value: string): GenericListOptionSettings | undefined

Find option by value.

protected
read(): Promise<boolean>

Read user input.

protected
selectNext(): void

Select next option.

protected
selectPrevious(): void

Select previous option.

Static Methods

Set list option defaults.

Create list separator.

import GenericList
import { GenericList } from "https://dotland.deno.dev/x/cliffy@v0.16.0/mod.ts";