Skip to main content
🌍 Public

Share visualization

Send this visualization to others.

Rendering data with React and D3

Public visualization

Rendering data with React and D3

0 stars1🌍 Public
YYibo Zhang
Last edited Jan 13, 2022
Created on Jan 13, 2022

This example displays a full-color donut chart of CSS named colors, rendered as SVG paths. It uses React hooks (useState, useEffect) to asynchronously load the dataset from a CSV via d3.csv, then computes pie angles with d3.pie and draws arcs with d3.arc. Each slice is filled using the color’s hex value from the data.

AI-generated description

Rendering Data with React and D3

Comments

Sign in to join the discussion.

MIT Licensed