Skip to main content
🌍 Public

Share visualization

Send this visualization to others.

Fork of Let's Make a Face Part I

Public visualization

Fork of Let's Make a Face Part I

0 stars0🌍 Public
PPatrick Byron Gattoc
Last edited Sep 25, 2021
Created on Sep 25, 2021

This example shows a simple smiley face built from three SVG circles—a yellow head with a black outline and two eyes—rendered in a React component. It demonstrates how to use React to declaratively construct an SVG scene, computing positions with the constants `centerX`, `centerY`, `eyeOffsetX`, `eyeOffsetY`, and `eyeRadius`. The code uses ReactDOM to mount the component into the DOM, and the SVG elements are styled with attributes like `fill`, `stroke`, and `stroke-width`. No interactivity or animation is present beyond the static frame.

AI-generated description

Half way towards a smiley face.

Comments

Sign in to join the discussion.

MIT Licensed