Skip to main content
100%

Mouse Follower

✓ Published1🌍 Public
DDusty
Last edited Jul 22, 2021
Created on Jul 21, 2021
Forked from Fork of Hello HTML

A circle follows the mouse cursor across an SVG canvas. React state tracks the pointer position, updating on every `mousemove` event, and re-renders the circle's `cx` and `cy` coordinates accordingly. The example uses React 17 with hooks (`useState`, `useCallback`) and renders through `ReactDOM`. D3 v7 is loaded but not directly used. The SVG has a fixed width of 960 pixels and height of 560 pixels, with the circle initially centered at the canvas midpoint.

AI-generated description

A program that follows your mouse with a circle.

MIT Licensed

Similar vizzes