Skip to main content
🌍 Public

Share visualization

Send this visualization to others.

Rendering Data with React & D3

Public visualization

Viewing a saved revision (read-only)

0d699f51e7a34af7a426acb3edff4e74

Rendering Data with React & D3

0 stars1🌍 Public
BBen Seebeck
Last edited Nov 4, 2021
Created on Nov 4, 2021

This example renders a radial burst of every CSS named color from a CSV dataset loaded with D3’s `csv` utility. The visualization shows a complete pie chart where each slice’s fill matches its corresponding hex value, using React state and `useEffect` to fetch the data. D3’s `pie()` and `arc()` functions compute the slice geometry, while React’s `map` method generates the SVG `path` elements. The code relies on React 17, ReactDOM, and D3 v7, all rendered as SVG in a 960×500 viewport.

AI-generated description

A program that loads in some data about CSS named colors using D3 utilities, and uses React state to render the data as a radial burst.