Skip to main content
100%

Rendering data with React & D3

✓ Published1🌍 Public
Jjbruzzo
Last edited Jun 30, 2022
Created on Jun 30, 2022

This example shows a vertical stack of colored bands, one for each named CSS color, rendered as full-width div elements. The application uses React’s `useState` and `useEffect` hooks to manage asynchronous loading of a CSV file from a GitHub gist via the D3 `csv` utility. Once the data arrives, React maps each row to a styled div whose background color is set from the `RGB hex value` column. The page initially displays a large “Loading…” placeholder until the dataset is fetched and processed.

AI-generated description

A program that loads in some data using D3 utilities, and uses React state to keep track of the data.

MIT Licensed

Similar vizzes