Skip to main content
100%

Fork of Rendering data with React

✓ Published1🌍 Public
BbeauMarko
Last edited Feb 26, 2021
Created on Feb 26, 2021

A pie chart displays CSS named colors as individual slices, with each slice filled using the color’s hex value from a CSV dataset loaded via `d3.csv`. The React component uses `useState` and `useEffect` to fetch and store the data, while `d3.pie` and `d3.arc` compute the arc paths rendered as SVG `<path>` elements. A loading fallback shows text until the data arrives, and the chart is centered within a fixed 960 by 500 viewport.

AI-generated description

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

MIT Licensed

Similar vizzes