/inquirer-loop

Inquirer loop prompt

Primary LanguageJavaScriptMIT LicenseMIT

Inquirer Loop

Package Travis GitHub

Inquirer loop prompt


Installation

npm install --save inquirer-loop

Usage

inquirer.registerPrompt("loop", require("inquirer-loop")(inquirer));

inquirer.prompt({
    type: "loop",
    name: "items",
    message: "Add another item?",
    questions: [
        {
            type: "input",
            name: "key",
            message: "Enter item key",
        },
        {
            type: "input",
            name: "value",
            message: "Enter item value",
        },
    ],
});

License

This project is licensed under the MIT license.
Copyright (c) KoLiBer (koliberr136a1@gmail.com)