Skip to main content
100%

Fork of Loading Data with React & D3

✓ Published0🌍 Public
Ccclime
Last edited Apr 9, 2022
Created on Apr 9, 2022

This example displays CSS named colors as horizontal stripes, with each stripe’s background color set from the `RGB hex value` field in the loaded dataset. The app uses React’s `useState` and `useEffect` hooks to manage asynchronous data loading, while D3’s `csv` utility fetches the data from a GitHub Gist. Before the data arrives, a “Loading…” message appears; once loaded, the map function renders a div per color record. The code relies on React 16.9, D3 v5, and the UMD builds from unpkg.

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.

MIT Licensed

Similar vizzes