learning-react
learning-react copied to clipboard
Invoke rejects() instead of reject()
Similar to the typo fixed in #25, the callback passed in as an argument is rejects, and not reject.
This can also be noticed in the currently linked JS Bin by simulating an error by changing the API endpoint:
const api = `https://api.randomuser.me/foo/?nat=US&results=${count}`
the output now becomes:
"grandpa23 -> attempted to load 20 fake members"
"ReferenceError: reject is not defined
at XMLHttpRequest.request.onload (xutamojacu.js:9:45)"
- [x] Fix code sample
- [x] Fix JSBin example
PS: Thank you @eveporcello and @MoonTahoe for the amazing book! It is a joy to read and learn from! ❤️ 💚 💙 💛 💜