Skip to main content
🌍 Public

Share visualization

Send this visualization to others.

Rendering DATA with React & D3

Public visualization

Rendering DATA with React & D3

0 stars1🌍 Public
Ssinghjy
Last edited Mar 9, 2021
Created on Mar 7, 2021

This example renders the CSS named colors as a pie chart using React and D3. It loads color data from a CSV file via `d3.csv`, then uses `d3.pie` and `d3.arc` to compute the pie slices, which are drawn as SVG `<path>` elements with the hex values as fills. The chart is centered in a 960×500 SVG canvas, with React state managing the asynchronous data loading and rendering the loading message until the data arrives.

AI-generated description

Uses react to render the data A program that loads in data using d3 utilities and react state to keep track of our data

Comments

Sign in to join the discussion.

MIT Licensed