Skip to main content
🌍 Public

Share visualization

Send this visualization to others.

Fork of ICE-6: Rendering Marks and Channels with React & D3

Public visualization

Fork of ICE-6: Rendering Marks and Channels with React & D3

0 stars1🌍 Public
TTharun2022
Last edited Mar 4, 2022
Created on Mar 4, 2022

This example visualizes the top 10 most populous countries in 2019 using a horizontal bar chart rendered with React and D3. It encodes population counts through bar lengths on a linear scale, with country names positioned along a band scale. The code loads CSV data via `d3.csv`, then uses React hooks like `useState` and `useEffect` to manage the data lifecycle. SVG marks are generated manually using React elements, while D3 utilities such as `scaleBand`, `scaleLinear`, and `max` handle scaling and domain calculations.

AI-generated description

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

See also React Starter.

Comments

Sign in to join the discussion.

MIT Licensed