Skip to main content
100%

Let's make a face with D3.js!

✓ Published0🌍 Public
AAndres Crovetto
Last edited Apr 10, 2020
Created on Apr 10, 2020

This example builds a cartoon face using D3.js v5 and SVG. The code draws a red circle for the head, two white circles for the eyes with black strokes, and a curved mouth created with the `d3.arc()` generator. All shapes are positioned relative to the SVG’s width and height, with eye offsets and the mouth placed inside a transformed group. The visualization relies entirely on basic SVG shape primitives and D3’s arc path helper, with no external data.

AI-generated description
MIT Licensed

Similar vizzes