Skip to main content
100%

Intro to D3

✓ Published0🌍 Public
PParker
Last edited Aug 25, 2020
Created on Aug 24, 2020
Forked from HTML Starter

This example builds a stylized smiley face entirely with React and SVG, using a full-screen viewport and centralized coordinates. The code defines circle elements for the head, two eyes, and an implied mouth, with properties like `eyeOffsetX`, `eyeRadius`, and `strokeWidth` controlling the layout. Rendered through ReactDOM, the face resizes to the browser window, drawing a yellow circle with a black stroke and two smaller black circles for eyes. The approach demonstrates how to compose SVG shapes programmatically in a React component rather than using D3’s data-binding utilities.

AI-generated description

Intro to D3.js

Purpose

MIT Licensed

Similar vizzes