0.1.1 • Published 7 years ago
confirm-promise v0.1.1
confirm-promise
A simple command-line tool to confirm
Install
$ npm install --save confirm-promise
Api
confirm(message [, chose] [, callback])
Example
var confirm = require('confirm-promise')
confirm('how are you', function(ok){
if(ok){ // ok is boolean
// I'm crazy
}
})
confirm('how are you')
.then(ok => {})
.catch(ok => {})
var ok = yield confirm('how are you');
var confirm = require('confirm-promise')
confirm('how are you', ['ok', 'cancel'] ,function(ok){
if(ok){ // ok is boolean
// I'm crazy
}
})