Skip to main content
🌍 Public

Share visualization

Send this visualization to others.

Rabbitface with D3.js

Public visualization

Rabbitface with D3.js

0 stars0🌍 Public
KKnightCrawler3
Last edited Apr 28, 2020
Created on Apr 28, 2020

A smiley face rendered as SVG with D3.js v5 demonstrates fundamental DOM manipulation by animating its eyebrows. The face is constructed using D3 selections and the `arc` generator for the mouth and left eyebrow, with circles for eyes and rectangles for teeth and the right eyebrow. A chained `transition` over two seconds moves the eyebrows downward, changes their fill to red, then returns them to their original position and color. The code imports `select` and `arc` from the D3 module and appends elements to an SVG 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