Created
August 14, 2021 15:05
-
-
Save chetanraj/b30a13048289d676a81a118fc4b701f7 to your computer and use it in GitHub Desktop.
getBookByNamePromise
This file contains 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
getBookByName('Art of War').then((book) => { | |
if (book) { | |
console.log('Found the book!'); | |
} else { | |
console.log('Book not found!'); | |
} | |
}); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment