Skip to main content
🌍 Public

Share visualization

Send this visualization to others.

mouse follower

Public visualization

mouse follower

0 stars0🌍 Public
MMegRocky
Last edited Jun 23, 2021
Created on Jun 23, 2021

A yellow smiley face follows the mouse cursor across an SVG canvas. The face’s components—eyes, brows, and an arc-shaped mouth—are built with React state and D3’s `arc` generator, repositioned via a `transform` attribute on each mouse move. The example uses `useState` and `useCallback` to track cursor coordinates, and ReactDOM renders the interactive graphic.

AI-generated description

A bare minimum HTML page.

Comments

Sign in to join the discussion.

MIT Licensed