Skip to main content
🌍 Public

Share visualization

Send this visualization to others.

a face with D3.js!, Migusti

Public visualization

a face with D3.js!, Migusti

0 stars0🌍 Public
RRemustus
Last edited Sep 3, 2021
Created on Sep 3, 2021

A smiling face rendered in SVG animates as its eyebrows rise and fall, demonstrating fundamental DOM manipulation with D3.js. The code uses d3.select to append circle, rect, and path elements, positioning them via SVG transform attributes. Eyebrow movement is created with chained transition() and duration(2000) calls, while the mouth uses d3.arc with defined innerRadius, outerRadius, and start/end angles. The yellow face and black features are drawn entirely through D3’s data-join-free imperative API on a fixed 960×500 canvas.

AI-generated description

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

Comments

Sign in to join the discussion.

MIT Licensed