Skip to main content
Public

Share visualization

Loading preview…

Fork II of Rendering data with React.

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 II of Rendering data with React.

1
Bbsolomon103
Last edited Dec 30, 2021
Created on Dec 30, 2021

This example displays a horizontal bar chart of the top ten countries by 2020 population, based on UN population data loaded as CSV via `d3.csv`. React manages the component state with `useState` and `useEffect` to fetch the data, while D3 v7 utilities `scaleBand` and `scaleLinear` map country names and population values to SVG rectangles. Rendering occurs through React’s virtual DOM into an SVG container, with a loading message shown before 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.

Comments

Sign in to join the discussion.

MIT Licensed