🌍 Public
Viewing a saved revision (read-only)
564c970e6f184602bfa7b05dcc0ed068
Let's make a face with D3.js!
A yellow smiley face with animated eyebrows demonstrates fundamental DOM manipulation with D3.js. The face is built entirely with SVG shapes selected and appended via `d3.select` and `selection.append`, including circles for the head and eyes, rectangles for eyebrows, and a path generated with `d3.arc` for the mouth. Eyebrows animate upward and back down using chained `transition.duration` calls that modify their `transform` attribute. The example uses D3 v5 and relies on SVG attributes like `cx`, `r`, and `d` to construct the static face.
AI-generated descriptionDemonstrates fundamental DOM manipulation using D3.js by making a smiley face whose eyebrows move.