Tratando de obtener estos géneros y guardarlos en una matriz llamada géneros que se pueden usar con dom y reaccionar. ¿Cómo hago esto? En este momento, todo lo que puedo hacer es consolarlos.
const genres = [""]; const options = { method: 'GET', headers: { 'X-RapidAPI-Key': '8a7d386af8msh99bcb7b70a0270ep1d0017jsn4f50689ce12a', 'X-RapidAPI-Host': 'moviesdatabase.p.rapidapi.com' } }; fetch('https://moviesdatabase.p.rapidapi.com/titles/utils/genres', options) .then(response => response.json()) .then(d => {for(let a of d.results){ if(a != null){ genres.push(JSON.stringify(a)); console.log(a); } }}) .catch(err => console.error(err)); console.log(genres);``` Any help would be appreciated. Let me know if you need anymore info as to what I am doing.