Skip to content

shahata/inquirer-timeout-confirm-prompt

Folders and files

NameName
Last commit message
Last commit date

Latest commit

Sep 28, 2024
b7ef87e · Sep 28, 2024

History

3 Commits
Dec 4, 2021
Sep 28, 2024
Sep 28, 2024
Sep 28, 2024
Sep 28, 2024

Repository files navigation

Timeout Confirm Prompt

Inquirer Confirmation prompt, automatic confirmation after timeout

Based on https://github.com/zonday/inquirer-timeout-confirm-prompt

Install

npm install --save @shahata/inquirer-timeout-confirm-prompt

Use

import timeoutConfirm from '@shahata/inquirer-timeout-confirm-prompt';

const answer = await timeoutConfirm({
  message: 'Are you sure you want to delete?', 
  timeout: 5, 
  timeoutTips: (t) => `(Automatic confirmation in ${t} seconds)`
});

console.log(answer);

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published