Skip to main content
Public

Share visualization

Loading preview…

Fork of Loading Data with React and D3

vizhub.com

Shared links may look like this on X, LinkedIn, Slack, and Discord.

Before sharing, review the publishing checklist.

Choose how to deliver this visualization

LinkedIn caption

LinkedIn may not keep text supplied by the share sheet. Copy the caption and paste it into the post if needed. You can tag the VizHub company page when posting.

More options

Embed on a websiteCopy iframe embed code
Download & exportPNG, HTML, source ZIP

Fork of Loading Data with React and D3

0
Cchar0496
Last edited Apr 16, 2022
Created on Apr 16, 2022

This example displays a summary of the CSS named colors dataset, showing its size in kilobytes, row count, and column count. It fetches the data from a remote CSV URL using D3’s `csv` utility and manages loading state with React’s `useState` and `useEffect` hooks. Once the data arrives, the `message` function formats the statistics for display, using `d3.csvFormat` to compute the byte size. The visualization is a simple text output rendered via ReactDOM, with a "Loading..." placeholder during the fetch.

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.

Comments

Sign in to join the discussion.

MIT Licensed