Dataviz 2020_Ep16 - 10. Loading Data with React and D3
✓ Published2🌍 Public
MMinwoo Pak
Last edited Jun 7, 2021
Created on Jun 6, 2021
This example demonstrates how to load and summarize a CSV dataset using D3 and React. It displays the file size in kilobytes, row count, and column count from the CSS named colors dataset. The code uses React’s `useState` and `useEffect` hooks to fetch the data via D3’s `csv` function from a GitHub gist URL, then formats it with `d3.csvFormat` and displays the result. React renders the summary text within a `<pre>` element while the data loads.
AI-generated descriptionA program that loads in some data using D3 utilities, and uses React state to keep track of the data.
MIT Licensed