useEffect(() => { requestPets(); }, []); async function requestPets() { const res = await fetch(API_URL); const json = await res.json(); setPets(json.pets) }
useEffect(() => { requestPets(); }, []); async function requestPets() { const res = await fetch(API_URL); const json = await res.json(); setPets(json.pets) }