Skip to main content
100%

Let's make a face with D3.js!

✓ Published0🌍 Public
AAlec Burch
Last edited Jun 3, 2019
Created on Jun 3, 2019

A yellow smiley face is drawn onto an SVG canvas using D3 selections, with circles for the eyes, rectangles for the eyebrows, and a D3 arc generator for the mouth. The eyebrows rise and lower via chained `transition` calls that animate the `transform` attribute over two seconds each. The example demonstrates fundamental DOM manipulation with `d3.select` and `append`, plus D3 v5’s modular imports for `select` and `arc`.

AI-generated description

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

MIT Licensed

Similar vizzes