Skip to main content
100%

Pie chart of CSS colours

✓ Published1🌍 Public
Vvangenned
Last edited Aug 11, 2022
Created on Aug 11, 2022

This example displays a pie chart where each slice corresponds to a CSS named color, filled with its own RGB hex value. The chart uses d3.csv to load color data from a GitHub gist, d3.pie to compute arc angles, and d3.arc to generate SVG path shapes. React manages the component state and renders the SVG elements, with a loading message shown before data arrives. The chart is rendered at 960 by 500 pixels with the pie centered and extending to the full chart width.

AI-generated description

A program that loads in some data about CSS named colours with d3 and uses react to reder data

MIT Licensed

Similar vizzes