@form8ion/overridable-prompts
v1.2.0
Published
Inquirer prompts that can be overriden with provided answers
Downloads
10,920
Readme
overridable-prompts
Inquirer prompts that can be overriden with provided answers
Table of Contents
Usage
Installation
$ npm install @form8ion/overridable-prompts --save-prod
Example
Import
import {prompt} from '@form8ion/overridable-prompts';
Execute
const answers = await prompt(
[
{
name: 'Question #1',
message: 'What should we ask first?'
},
{
name: 'Question #2',
message: 'What should we ask second?',
when: answerList => 'Provided answer for `Question #1`' === answerList['Question #1']
}
],
{
'Question #1': 'Provided answer for `Question #1`',
'Question #2': 'Provided answer for `Question #2`'
}
);
Contributing
Dependencies
$ nvm install
$ npm install
Verification
$ npm test