Skip to main content
100%

Let's make a face with D3.js!

✓ Published4🌍 Public
SSimon Pettersson
Last edited Apr 14, 2020
Created on Apr 8, 2020
Forked from HTML Starter

This example demonstrates how to construct a simple animated face using D3.js, with a yellow circular head, eyes, eyebrows, and a mouth drawn using `d3.arc`. The code renders the face as SVG elements within a React framework, using `select` and `arc` from D3 to build the shapes. A `transition` animates the eyebrows upward and back down repeatedly, creating a blinking or surprised expression. The face is centered within a 960x500 SVG canvas, with all geometry derived from hardcoded dimensions rather than external data.

AI-generated description

A bare minimum HTML page.

See also React Starter.

MIT Licensed

Similar vizzes