Skip to main content
100%

Let's make a face with D3.js!

✓ Published0🌍 Public
AAkshada Pradhan
Last edited May 16, 2020
Created on May 16, 2020

A yellow smiley face is drawn in SVG using D3.js, with circles for eyes and a mouth created via the d3.arc path generator. The face’s eyebrows, rendered as rectangles, animate upward and back down over four seconds using chained transition calls. The code builds the entire face through direct DOM selection and manipulation with d3.select and d3.append, positioning elements via SVG transform attributes.

AI-generated description

Demonstrates fundamental DOM manipulation using D3.js by making a smiley face whose eyebrows move.

MIT Licensed

Similar vizzes