Skip to main content
100%

Let's make a face with D3.js

✓ Published2🌍 Public
AAndrewRiceMGW
Last edited Jan 3, 2021
Created on Jan 3, 2021

This example builds a cartoon face from SVG shapes using D3.js v6, with yellow circular head, eyes, eyebrows, and a mouth drawn using the `d3.arc` path generator. The code animates the eyes by transitioning their radius attribute and shifts the eyebrow group’s transform property through sequential `transition.duration` calls. All elements are centered within an SVG via a translated group, and the face is constructed entirely from static shape attributes rather than data binding or external data sources.

AI-generated description
MIT Licensed

Similar vizzes