Skip to main content
100%

Fork of Smiley Face Part II

✓ Published0🌍 Public
Sstpvizzy
Last edited Mar 16, 2021
Created on Mar 16, 2021

This example renders a full-window smiley face using React and SVG. The face consists of three circles—a yellow head, and two eyes—drawn with SVG `<circle>` elements inside a `<g>` transform, with dimensions and positions computed from `window.innerWidth` and `window.innerHeight`. The code uses React 16.9.0 and ReactDOM directly from UMD builds to mount the component onto a `<div id="root">` element. The face is centered dynamically, but no mouth is drawn despite the title referencing a smiley face.

AI-generated description

Smiley face implementation with React.

MIT Licensed

Similar vizzes