🌍 Public
Viewing a saved revision (read-only)
6aed19ed78f14f7bb1dbef6ba48fd39a
Let's make a face with D3.js!
This example demonstrates fundamental D3.js DOM manipulation by building an animated smiley face with moving eyebrows. It renders an SVG scene with a yellow circular head, eyes, and a mouth created using the `d3.arc` path generator. The eyebrows are rectangles that animate upward and downward via chained `transition.attr` calls, moving over two seconds each way. The code uses D3 v5 selections and attributes to construct and position all elements relative to a centered group.
AI-generated descriptionDemonstrates fundamental DOM manipulation using D3.js by making a smiley face whose eyebrows move.