Skip to main content
100%

smiley face with D3.js

✓ Published0🌍 Public
GGreatGayatri
Last edited Aug 9, 2023
Created on Aug 9, 2023
Forked from Fork of D3 Starter

This example draws a smiley face entirely with SVG shapes using D3.js v7. It creates a yellow circle for the head, two black circles for the eyes, and a mouth generated with the `d3.arc` shape generator. The arc uses `innerRadius`, `outerRadius`, and angular start/end values to form a crescent-like smile. All shapes are positioned relative to the SVG's width and height attributes, with the mouth translated to the center of the canvas.

AI-generated description

A demonstration of how to start using D3 version 6.

MIT Licensed

Similar vizzes