Skip to main content
100%

4. Loading Data with React and D3

✓ Published0🌍 Public
DDenis Zjukow
Last edited Sep 14, 2021
Created on Sep 14, 2021
Forked from 3. Mouse follower

This example demonstrates how to load and summarize CSV data in a React component using D3. It fetches a remote dataset of CSS named colors via `d3.csv`, stores the result in React state with the `useState` and `useEffect` hooks, and displays a text summary of the file size, row count, and column count. The rendering uses ReactDOM to mount the component, while `d3.csvFormat` calculates the data size in kilobytes. The visualization is purely textual, showing a loading message until the data arrives.

AI-generated description

A bare minimum HTML page demonstrating use of CSS and JavaScript.

See also React Starter.

MIT Licensed

Similar vizzes