Skip to main content
100%

Rendering data with react

✓ Published2🌍 Public
SSreekar Reddy
Last edited May 13, 2021
Created on May 13, 2021

A bar chart displays the top 10 countries by 2020 population, loaded from a UN dataset via `d3.csv`. React's `useState` and `useEffect` manage the asynchronous data fetching, while `d3.scaleBand` positions bars on the y-axis and `d3.scaleLinear` maps population values to widths. The SVG rectangles render through React components, with `d3.max` setting the x-domain.

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