Skip to main content
100%

4.43BarChartReact needs refactor @5.17

✓ Published2🌍 Public
Cchristine
Last edited Oct 31, 2022
Created on Oct 5, 2022
Forked from Hello VizHub

This bar chart displays the population of ten countries from the United Nations 2019 population data. The visualization uses D3 v7 utilities such as `scaleBand`, `scaleLinear`, and `max` to construct the chart, while React 18 components handle the rendering of SVG axes and marks. Each bar’s height is determined by the band scale, and its width reflects the population magnitude, with hover tooltips showing formatted values. The code also includes a custom `useData` hook that fetches CSV data via D3’s `csv` method.

AI-generated description

A program that loads in some data about CSS named colors using D3 utilities and React to render the data.

MIT Licensed

Similar vizzes