@yukikaze-bot/prompt
v2.0.7
Published
A simple cli prompter.
Downloads
4
Readme
@yukikaze-bot/prompt
A simple prompter for your cli.
Table of Contents
Description
Prompts user input from the cli!
Features
- Written in TypeScript
- Offers CommonJS, ESM bundles
- Fully tested
Installation
yarn add @yukikaze-bot/prompt
# npm install @yukikaze-bot/prompt
Usage
Note: While this section uses require
, the imports match 1:1 with ESM imports. For example const { prompt } = require('@yukikaze-bot/prompt')
equals import { prompt } from '@yukikaze-bot/prompt'
.
Note: When using ESM syntax you can also default-import prompt
function: import prompt from '@yukikaze-bot/prompt'
.
Basic Usage
const { prompt } = require('@yukikaze-bot/prompt');
const response = prompt('What is your name?');
console.log(`Your name is: ${response}`);
API Documentation
For the full API documentation please refer to the TypeDoc generated documentation.