Play with React & D3
✓ Published0🌍 Public
This example shows CSS named colors as concentric donut rings, with three nested pie charts rendered at three positions on the screen. Each ring segment’s fill equals the hex value of the corresponding color from the dataset. The code uses React’s `useState` and `useEffect` to load the CSV named-color data, then renders SVG paths using `d3.csv`, `d3.pie`, and `d3.arc` with fixed inner and outer radii. Three separate arc configurations create the layered rings, and the same pie layout is reused for each cluster.
AI-generated descriptionMIT Licensed