HTML Starter
✓ Published1🌍 Public
This example demonstrates a simple data-join visualization of fruit shapes, showing apples and lemons as colored circles with labels. It uses D3 v5’s `scaleOrdinal` to map fruit types to colors (red for apples, yellow for lemons) and radii (50 vs. 20 pixels). The code employs the general update pattern with `selection.selectAll`, `enter`, `merge`, and `exit` to handle adding, removing, and updating fruits over time via `setTimeout`. The visualization renders inside an SVG container within a React scaffold, with a rounded rectangle representing a bowl.
AI-generated descriptionA bare minimum HTML page.
See also React Starter.
MIT Licensed