Skip to main content
100%

Rendering data with React

✓ Published1🌍 Public
11tang
Last edited Apr 10, 2021
Created on Apr 10, 2021

This example shows CSS named colors as a horizontal stacked bar chart, where each color is a thin rectangular strip. Using React and D3, the app fetches color data from a CSV file via D3’s `csv` utility, then maps each row to a colored `<div>` with a fixed width and height. The visualization relies on React’s `useState` and `useEffect` hooks for asynchronous data loading and rendering, with a “Loading…” message displayed until the data arrives.

AI-generated description

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

MIT Licensed

Similar vizzes