Skip to main content
100%

Let's make a face with D3.js!

✓ Published0🌍 Public
DDonisius Wigie
Last edited Oct 6, 2019
Created on Oct 5, 2019
Forked from Hello VizHub

This example uses D3.js to draw a cartoon face on an SVG canvas. The face consists of a yellow circle for the head, two dark circles for eyes, and a semi-circular path for the mouth, all positioned with D3’s `select` and `append` methods. The `arc()` API generates the mouth’s curved shape, while `attr` calls set dimensions and styles. The code imports functions from the D3 v5 library and works with an SVG element sized at 960 by 500 pixels.

AI-generated description

An example showing the capabilities of VizHub.

MIT Licensed

Similar vizzes