Share your code. npm Orgs help your team discover, share, and reuse code. Create a free org »

    stdaskpublic

    stdask gives a simple interface for asking the user for command line inputs

    Installation

    npm install stdask

    API The second argument is an optional regex filter with which the users input will be processed

    ask( questionString, optionalRegexFilter, callback )

    Usage

    var ask = require("./stdask").ask;
     
    ask("Enter your name", function(name) {
        ask("Enter your email", /^.+@.+$/, function(email) {
            console.log("Your name is: ", name);
            console.log("Your email is:", email);
         
            process.exit();
       });
    });

    Keywords

    none

    install

    npm i stdask

    Downloadsweekly downloads

    1

    version

    0.0.3

    license

    none

    repository

    github.com

    last publish

    collaborators

    • avatar