Data Fetching with React
Explore how to fetch live data in React by using the Hacker News API and the native fetch function. Understand managing asynchronous state and JSON data conversion to build dynamic React applications.
We'll cover the following...
We'll cover the following...
We are currently fetching data, but it’s still pseudo data coming from a promise we set up ourselves. The lessons up to now about asynchronous React and advanced state management were preparing us to fetch data from a real third-party API. We will use the reliable and informative Hacker News API to request popular tech stories.
Instead of using the initialStories array and getAsyncStories function (you can remove these), we will fetch ...