🌍 Public
Viewing a saved revision (read-only)
7da19cafb83a4c0aa94c0a1f13d5b862
Let's make a face with D3.js
This example shows a yellow smiley face drawn with SVG shapes, where the eyebrows repeatedly rise and lower in a looping two-second animation. The face is constructed using D3 selections to append a circle, two eye circles, two rectangular eyebrows, and a mouth path generated with the `arc` helper. The animation is implemented by chaining `transition().duration(2000)` calls on the eyebrows group, toggling its vertical transform. All geometry is positioned relative to the center of the SVG using a translated group.
AI-generated descriptionA bare minimum HTML page.
See also React Starter.