🌍 Public
Viewing a saved revision (read-only)
e05a51b3e5294a44b20bdacf98d68369
Axes with React & D3
This example shows a horizontal bar chart of the ten most populous countries in 2020, rendered as SVG elements. React manages the component state and renders each bar as a `<rect>`, while D3 utilities handle data loading with `d3.csv` and scaling with `scaleBand` and `scaleLinear`. The data comes from a UN population dataset hosted as a CSV file. The chart updates reactively when the asynchronous data fetch completes, displaying a loading message until then.
AI-generated descriptionA program that loads in some data about CSS named colors using D3 utilities, and uses React to render the data as a radial burst!