Skip to main content
🌍 Public

Share visualization

Send this visualization to others.

Loading Data with React & D3

Public visualization

Viewing a saved revision (read-only)

3b836d7c25624435a2f8ecc816de9925

Loading Data with React & D3

0 stars1🌍 Public
Yyastika
Last edited Apr 17, 2021
Created on Apr 9, 2021

This example demonstrates loading CSS named color data using React state and D3 utilities. The app displays a simple text summary showing the data size in kilobytes, row count, and column count, with a loading message before data arrives. It uses React’s `useState` hook to store the parsed CSV data and D3’s `csv` function to fetch and parse the remote dataset from a GitHub gist. The rendered output is a large `<pre>` element styled with a 5em font size, showing the computed metrics dynamically.

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.