Skip to main content
Module

x/cliffy/examples/keypress/promise.ts

Command line framework for deno 🦕 Including Commandline-Interfaces, Prompts, CLI-Table, Arguments Parser and more...
Extremely Popular
Go to Latest
File
#!/usr/bin/env -S deno run --unstable
import { keypress, KeyPressEvent } from "../../keypress/mod.ts";
const event: KeyPressEvent = await keypress();
console.log( "type: %s, key: %s, ctrl: %s, meta: %s, shift: %s, alt: %s, repeat: %s", event.type, event.key, event.ctrlKey, event.metaKey, event.shiftKey, event.altKey, event.repeat,);