dm-prompt
## Description - A module for simplyfying the usage of nodejs prompts. - Currently based on [inquirer](https://www.npmjs.com/package/inquirer) - make it possible to yield a inquirer Prompt - has to be used within [co](https://www.npmjs.com/package/co) - [
Last updated 2 years ago by divramod .
ISC · Repository · Bugs · Original npm · Tarball
$ cnpm install dm-prompt 
SYNC missed versions from official npm registry.

dm-prompt

Description

  • A module for simplyfying the usage of nodejs prompts.
  • Currently based on inquirer
  • make it possible to yield a inquirer Prompt
  • has to be used within co
  • inquirer examples

Install

npm install dm-prompt --save

Usage

var dmPrompt = require("dm-prompt").Inquirer;
var co = require("co");

var job = {};

job.start = co.wrap(function*() {
    // for other options see inquirer examples
    var directoryAnswer =
        yield dmPrompt({
            type: "input",
            name: "directory",
            message: "Please state the Directory to where node_modules should link to:"
        });
    var directory = directoryAnswer.directory;
    console.log(directory);
});

module.exports = job;

Tasks

Config

  • you can place a .dm-prompt.json file in your home directory (~/.dm-prompt.json)
  • the following things are allowed at the moment
{
}

Lessons Learned

Maintainers (1)
Downloads
Today 0
This Week 0
This Month 0
Last Day 0
Last Week 0
Last Month 14
Dependencies (11)
Dev Dependencies (3)

Copyright 2014 - 2017 © taobao.org |