const btn = document.getElementById("btn")
const foodDisplay = document.getElementById("foodHolder")
const findYum = async () => {
const response = await fetch('https://foodish-api.herokuapp.com/api/images/dessert')
const data = await response.json()
foodDisplay.innerHTML = `<img src='${data.image}' />`
}
btn.addEventListener("click", findYum)
/* Task:
Call the Foodish API (https://foodish-api.herokuapp.com/) and display random images of desserts on
the click of a button.
Specific URL to get a random dessert image:
https://foodish-api.herokuapp.com/api/images/dessert
Stretch goals:
- Show multiple desserts.
- Add the functionality to go back to the previous image.
*/