We're going to kick this section off by converting both getExchangeRate and getCountries over to async functions. They're good candidates because we do have promises and we could just await those promises instead. Then we're going to talk about errors, how we can throw them and how we can customize errors that get thrown by other code. It's going to make it really useful and it'll make it a lot easier to actually use async/await in the real world where you do need to handle errors.
Handling errors and awaiting async function
Converting getExchangeRate and getCountries into the async function
So the first thing we're going to do is convert getExchangeRate and getCountries. The first...