Skip to main content
100%

Fork of Loading Data with React & D3

✓ Published0🌍 Public
Vvitsenklavitsen
Last edited Mar 6, 2021
Created on Mar 6, 2021

This example loads CSS named color data from a CSV file using D3’s `csv` utility and manages the asynchronous result with React’s `useState` and `useEffect` hooks. While the data is pending, a "Loading..." message appears. Once loaded, it renders an SVG donut chart where each slice represents one color, filled with its own RGB hex value and positioned using D3’s `pie` and `arc` generators. The visualization directly maps the dataset’s categorical entries to equal-sized arcs, effectively showcasing the full palette.

AI-generated description

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

MIT Licensed

Similar vizzes