Skip to main content
🌍 Public

Share visualization

Send this visualization to others.

Fork of Rendering data with react

Public visualization

Fork of Rendering data with react

0 stars0🌍 Public
Ccaptind
Last edited Feb 24, 2023
Created on Feb 24, 2023

This example visualizes CSS named colors as a pie chart, with each slice colored by its corresponding RGB hex value. It loads color data from a CSV file using D3’s `csv` utility, then manages the fetched data through React’s `useState` and `useEffect` hooks. The chart is rendered as SVG paths, with each arc computed using D3’s `arc` generator and positioned around a central point. While the data loads, a large loading message appears in place of the visualization.

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.

Comments

Sign in to join the discussion.

MIT Licensed