Published
Edited
Mar 11, 2021
1 star
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
async function fetchTopStories() {
let stories = {};
for (var i = 0; i < 20; i++) {
let storyId = topStoryId[i];
let storyDetailsURL = `https://hacker-news.firebaseio.com/v0/item/${storyId}.json`;
let response = await fetch(storyDetailsURL);
stories[storyId] = await response.json();
}

return stories;
}
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell
Insert cell

Purpose-built for displays of data

Observable is your go-to platform for exploring data and creating expressive data visualizations. Use reactive JavaScript notebooks for prototyping and a collaborative canvas for visual data exploration and dashboard creation.
Learn more