Skip to main content
100%

Rendering Data (Radial Burst) with React

✓ Published1🌍 Public
AAnthonyAl-Rifai
Last edited Feb 20, 2023
Created on Feb 20, 2023

This example displays a radial burst visualization of CSS named colors, loading data from a CSV of color names and their hexadecimal RGB values. The React component uses the `useState` and `useEffect` hooks to fetch the data with `d3.csv` and store it in state, then renders SVG paths generated with `d3.pie` and `d3.arc` functions. Each slice of the pie chart is filled with its corresponding color, creating a dramatic circular spectrum that spans the full width of the 960x500 viewport. While loading, the app shows "Loading..." text until the data arrives.

AI-generated description

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

MIT Licensed

Similar vizzes