🌍 Public
Viewing a saved revision (read-only)
7eac622909a24959ab85e3f2cfa67ea9
Let's make a face with D3.js!
This example demonstrates how D3.js v5 can manipulate SVG elements to create an animated smiley face. It shows fundamental DOM selection and appending via `d3.select`, `d3.arc` for the mouth path, and `transition.attr` to animate the eyebrows by shifting their vertical offset over two 2-second intervals. The face is rendered as a yellow circle with black strokes, positioned using SVG transformations, with rectangles acting as eyebrows that move up and down while the eyes and mouth remain static.
AI-generated descriptionDemonstrates fundamental DOM manipulation using D3.js by making a smiley face whose eyebrows move.