termprompt

Prompts

Overview of all 6 interactive prompt types in termprompt.

Prompts

termprompt ships 7 interactive prompt types. All return Promise<T | Cancel> and support cancellation via Esc or Ctrl+C.

At a Glance

select
Pick a framework
Next.js (React SSR)
○ Hono
○ Astro
confirm
Deploy to production?
Yes / No
input
Project name?
my-app
multiselect
Select features
> TypeScript
ESLint
Vitest
password
Enter your API key
••••••••
search
Select timezone
pac
Pacific (UTC-8)
○ Asia/Pacific
number
Port number?
8080

Summary

PromptReturnsUse case
selectTPick one from a list
confirmbooleanYes/no question
inputstringFree text with optional validation
multiselectT[]Pick multiple from a list
passwordstringMasked text input
searchTType-to-filter select
numbernumberNumeric input with step controls

Common Keyboard Shortcuts

KeyAction
EnterSubmit
EscCancel
Ctrl+CCancel

On this page