Fork of Axes with React & D3
✓ Published0🌍 Public
This example displays a horizontal bar chart of the top 10 most populous countries, using React for the user interface and D3 v5 for the underlying data handling and SVG rendering. It loads the dataset from a remote CSV file, parses the 2020 population column, and maps each country name to a categorical y-scale while scaling the bar widths with a linear x-scale. The chart includes axis ticks and labels generated via D3’s `scaleBand`, `scaleLinear`, and `max` functions, with React components constructing the SVG elements.
AI-generated descriptionA program that shows the top 10 most populous countries as a pathetic bar chart with no axes.
MIT Licensed