🌍 Public
Fork of Loading Data with React and D3
This example demonstrates the use of D3 utilities and React state to load and summarize a dataset of CSS named colors. It shows both a loading message and a three-line summary of the data: size in kilobytes, number of rows, and number of columns. The code uses React's `useState`, `useEffect`, and `d3.csv` to fetch the remote CSV file, then formats it with `d3.csvFormat` within a custom `message` function. The React application renders the text output inside a `<pre>` element.
AI-generated descriptionA program that loads in some data about CSS named colors using D3 utilities, and uses React state to keep track of data.
MIT Licensed
Comments
Sign in to join the discussion.