Welcome to the Treehouse Community
Want to collaborate on code errors? Have bugs you need feedback on? Looking for an extra set of eyes on your latest project? Get support with fellow developers, designers, and programmers of all backgrounds and skill levels here with the Treehouse Community! While you're at it, check out some resources Treehouse students have shared here.
Looking to learn something new?
Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and join thousands of Treehouse students and alumni in the community today.
Start your free trialThom Benjamin
10,494 PointsHow to practise Promises, API fetches and async awaits
I've completed the entire front dev track, and everything is perfectly clear to me now, except the three mentioned. I think I understand Promised and the fetch method and I can follow them when I see it written out, but I need a lot more practise. Async awaits seem to make things more complicated instead of easier to me.
Does someone know good API's or projects to try and work out as a way of practising these concepts?
Thanks!
1 Answer
Clayton Perszyk
Treehouse Moderator 48,850 PointsMaybe build an app that gets all songs for an artist on spotify:
- input for entering artist search
- list out results
Implement three times with promises, fetch, and async/await, and reflect on the differences.
Additional Resources:
https://dev.to/shoupn/javascript-fetch-api-and-using-asyncawait-47mp
https://itnext.io/javascripts-async-await-versus-promise-the-great-debate-6308cb2e10b3
Thom Benjamin
10,494 PointsThom Benjamin
10,494 PointsWow, there's an API for Spotify? Awesome, thanks!