🌍 Public
Viewing a saved revision (read-only)
203a0b12ae2a4cb9bfa6ce4988a7c5a8
Bowl of Fruit - General Update Pattern Special Cases
0007ebey
Last edited Oct 5, 2020
Created on Aug 12, 2020
A bowl of fruit demonstrates the general update pattern's special cases: adding, removing, and modifying items in a dataset. Apples and lemons are drawn as circles with corresponding colors and radii, positioned in a row within a rounded rectangle. Using d3.select, the code appends or removes groups via transitions, updating circle radii and fill colors with scaleOrdinal, and handles keyed filtering for deletion of a specific item.
AI-generated description