So am working with multiple prompts called from different files like this :
vorpal.command('init').description ('Create the configuration file for the project.').action(function(args, cb){const self = this;cordovaTasker.createConfig;})
The function createConfig simply provides a prompt like this :
var formulaire = [{...},{...}];
vorpal.command('bake [type]').description ('Generation Cordova.').autocomplete(['corn', 'steak', 'pasta']).option('-ng, --angular', 'Generate a cordova project with AngularJS architecture').action(function(args, cb){const self = this;this.prompt(formulaire, function(answers){displayModule.infoOut('Test affichage');console.log('\n Review _______________________ ');console.log(JSON.stringify(answers, null, ' '));});}).cancel(function () {this.log('Didn\'t mother teach you to be patient?');}).show();};
Is it possible to have prompts called out like this ? #
So am working with multiple prompts called from different files like this :
vorpal
.command('init')
.description ('Create the configuration file for the project.')
.action(function(args, cb){
const self = this;
cordovaTasker.createConfig;
})
The function
createConfig
simply provides a prompt like this :var formulaire = [{...},{...}];
vorpal
.command('bake [type]')
.description ('Generation Cordova.')
.autocomplete(['corn', 'steak', 'pasta'])
.option('-ng, --angular', 'Generate a cordova project with AngularJS architecture')
.action(function(args, cb){
const self = this;
this.prompt(formulaire, function(answers){
displayModule.infoOut('Test affichage');
console.log('\n Review _______________________ ');
console.log(JSON.stringify(answers, null, ' '));
});
})
.cancel(function () {
this.log('Didn\'t mother teach you to be patient?');
})
.show();
};
Is it possible to have prompts called out like this ? #