Skip to main content
100%

Alankruth

✓ Published0🌍 Public
AAlankruthSai
Last edited Mar 5, 2022
Created on Mar 5, 2022

This example displays a horizontal bar chart of units sold by country, using a dataset loaded from a CSV file. The chart renders as SVG within a React component, with D3.js handling data loading, scales, and axes. It uses `scaleBand` for the categorical y-axis, `scaleLinear` for the quantitative x-axis, and maps data to `<rect>` elements. Grid lines and axis tick labels are generated from the scales' tick values. The visualization is built with React hooks (`useState`, `useEffect`) and updates once the CSV data is fetched and parsed.

AI-generated description

A bare minimum HTML page demonstrating use of CSS and JavaScript.

See also React Starter.

MIT Licensed

Similar vizzes