hadith-cli
Version:
This is a CLI for hadith on terminal
1 lines • 688 B
JavaScript
const chalk=require("chalk"),{prompt:prompt}=require("enquirer"),{requestProcessor:requestProcessor}=require("./requestProcessor"),volumeQuestions=[{type:"rawlist",name:"Volume",choices:["Volume 1","Volume 2"],message:chalk.green("Please Select the Volume No. of Hadith ?")}],queries=[{type:"input",name:"volume",message:"Please tell us what volume no you want to look through?"},{type:"input",name:"book",message:"Please tell us book no of this volume?"},{type:"input",name:"hadithNo",message:"Please tell us hadith no you are looking?"}],volumeSelector=()=>{prompt(queries).then(({volume:e,book:o,hadithNo:s})=>{requestProcessor(e,o,s)})};module.exports={volumeSelector:volumeSelector};