🌍 Public
Viewing a saved revision (read-only)
edc25ab9d4234b3c9351e54e70c06657
Refactored Bar Chart
This horizontal bar chart displays the population of five countries using D3’s `scaleBand` and `scaleLinear` utilities within a React component. The SVG rendering separates axes and marks into reusable modules (`AxisBottom`, `AxisLeft`, `Marks`), while `useData` fetches a CSV via D3’s `csv` and formats values with `format(".2s")`. The visualization retrieves data from a GitHub gist, applying a Poppins font and a teal fill to the bars.
AI-generated descriptionA program that loads in some data using D3 utilities, and uses React state to keep track of the data.