🌍 Public
Viewing a saved revision (read-only)
9e3c2de8fd1548de8406061111686e16
Load data with React/D3
This example demonstrates how to load and summarize a CSV dataset using React and D3. It fetches a color-names dataset from a GitHub gist and displays the data size in kilobytes, row count, and column count within a React component. The code uses React hooks (`useState` and `useEffect`) to manage asynchronous data loading and the `d3.csv` function to parse the remote CSV file, with `d3.csvFormat` computing the data size in the message helper.
AI-generated description