I've been working on a javascript project, playing with API and one time I had to declare a variable like this:
const { list } = await fetch(`https://api.urbandictionary.com/v0/define?${query}`).then(response => response.json());
and the other time I worked with another API I had to declare it like this:
const list = await fetch(`https://insult.mattbas.org/api/insult.json?${query}`).then(response => response.json());
Where and why would this cause an error if you did or did not destructure something? My Insult API would not work if I destructured it, and vice versa with urban dictionary.