🌍 Public
Interactions
A horizontal bar chart displays weight data for five people, loaded from a local CSV file with d3.csv. Bars are colored blue by default; hovering turns a bar red, and clicking updates a details panel with the person’s name. A vertical red line follows the mouse position using d3.mouse on the SVG container. The chart uses d3.scaleLinear for bar widths, d3.scaleBand for positioning, and d3.axisLeft for the y-axis, with SVG rectangles and animated transitions for rendering.
AI-generated descriptionA bare minimum HTML page demonstrating use of CSS and JavaScript.
See also React Starter.
MIT Licensed

![[05] Interactivity - Using React Hooks with D3](/viz/a12574a3398948a28dce5c3a78492b83/social-image.png?v=7fbf09e8afec4d96800bb9295ea53716)






Comments
Sign in to join the discussion.