Skip to main content
🌍 Public

Share visualization

Send this visualization to others.

Let's make a face with D3.js!

Public visualization

Viewing a saved revision (read-only)

2a9bef36e80a4d12b5a9374d81a1461e

Let's make a face with D3.js!

0 stars1🌍 Public
CCloron
Last edited Mar 21, 2020
Created on Mar 21, 2020

This example uses D3.js to draw a cartoon face in an SVG canvas. The face is composed of a yellow circle for the head, two black ellipses for eyes, and a black path for the mouth with rounded line joins. The code builds the graphic by appending SVG shapes to the root element, using method chaining to set attributes like radii, coordinates, and stroke properties in a concise, procedural manner.

AI-generated description

A bare minimum HTML page.

See also React Starter.