Develop/index.js
// TODO: Create a function to initialize app
Create a function to initialize app
Create a function to initialize app
function init() {
    inquirer
        .prompt(questions)
        .then((answers) => {
            writeToFile('./output/README.md', answers);
  })
  .catch((error) => {
    if (error.isTtyError) {
        console.log(error)
    } else {
        console.log(error)
    };
});
}
function init ( ) { inquirer . prompt ( questions ) . then ( ( answers ) => { writeToFile ( './output/README.md' , answers ) ; } ) . catch ( ( error ) => { if ( error . isTtyError ) { console . log ( error ) } else { console . log ( error ) } ; } ) ; }
TODO: Create a function to initialize app
TODO : Create a function to initialize app
// prompts user using questions array we locally required // then uses the answers as data to use in our custom writeToFile function // names file and selects where it is saved, gives data parameter set as users answers from prompt // Prompt couldn't be rendered in the current environment // Something else went wrong