Skip to main content
100%

D3-1: Making a face

✓ Published19🌍 Public
Bbkopruluoglu3
Last edited Sep 6, 2023
Created on Dec 27, 2022

A face made of SVG primitives is assembled with D3: a yellow circle forms the head, blue circles form the eyes, an arc path creates the mouth, and rectangles serve as eyebrows. The eyebrows animate by moving upward and then returning to their original position, using D3’s `transition` to shift their `y` attribute over time. The code uses `d3.select` to target the SVG element, `d3.arc` to define the mouth’s path, and SVG’s `circle`, `rect`, and `path` elements for rendering.

AI-generated description
MIT Licensed

Similar vizzes