Skip to main content
100%

Let's make a face with D3.js

✓ Published2🌍 Public
MMelissa Prax
Last edited Feb 17, 2020
Created on Feb 11, 2020

This example builds a cartoon face from basic SVG shapes using D3.js. A yellow circle forms the head, with two smaller circles for eyes and rectangles for eyebrows, all positioned via SVG attributes and transformations. A mouth is created using the D3 `arc` generator to produce a curved path. The code selects the SVG element, centers a group with a translation, and applies static coordinates and dimensions throughout.

AI-generated description

An example including some commonly used features of SVG.

MIT Licensed

Similar vizzes