function getCharacters(done) { const results = fetch("https://rickandmortyapi.com/api/character"); results .then(response => response.json()) .then(data => { done(data) }); } getCharacters(data => { console.log(data); data.results.forEach(personaje => { const article = document.createRange().createContextualFragment( /*html*/`
Personaje

${personaje.name}

${personaje.status}
`); const main = document.querySelector("main") main.append(article) }); });