Skip to main content
100%

My Own Smiley Face

✓ Published0🌍 Public
MMartin Blatz
Last edited Sep 24, 2020
Created on Sep 2, 2020

This example displays a yellow smiley face with rosy cheeks, eyebrows, and a wide smile, rendered as an SVG in a React component. It uses React 16.13.1 and D3 v6’s `arc` generator to create the mouth path, while circles define the face, eyes, pupils, and cheeks, with static coordinate offsets. The face is centered at (480, 250) on a 960×500 canvas, drawing all shapes within a single `<g>` transform. The code demonstrates a straightforward composition of React elements and D3’s arc API for a custom iconic graphic.

AI-generated description

My adjusted smiley face implementation with React & D3 forked from Professor Kelleher's profile. I've added eyebrows, stretched the smile a bit, and added rosy cheeks.

MIT Licensed

Similar vizzes