Skip to main content
🌍 Public

Share visualization

Send this visualization to others.

Fork of Loading Data with React & D3

Public visualization

Viewing a saved revision (read-only)

58729f1be4bd48b197120c83e65e6864

Fork of Loading Data with React & D3

0 stars0🌍 Public
Fflroent
Last edited Oct 20, 2021
Created on Oct 20, 2021

This example demonstrates a concise display of metadata about a dataset of CSS named colors, showing the file size in kilobytes, row count, and column count as plain text. The React component uses the `useState` and `useEffect` hooks to manage asynchronous data loading, while D3’s `csv` function fetches the remote CSV file. The `d3.csvFormat` utility calculates the data size, and ReactDOM renders the result, displaying “Loading...” until the data arrives.

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.