Last active
January 19, 2019 23:42
-
-
Save theptrk/e6a61559934fbcfa32cfc6e22b03a2d6 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
const chalk = require('chalk') | |
const inquirer = require('inquirer') | |
const promptSignup = () => { | |
const questions = [ | |
{ | |
message: 'Whats hannenin\'??', | |
name: 'action', | |
type: 'list', | |
choices: ['did', 'task'] | |
}, | |
{ | |
message: 'Message', | |
name: 'message' | |
} | |
]; | |
return inquirer.prompt(questions) | |
} | |
const run = async () => { | |
console.log(chalk.green('Welcome to your new tool')) | |
const { action, message } = await promptSignup(); | |
const entry = `(${action}) - ${message}` | |
// TODO do something with the entry | |
} | |
run() |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment