Skip to main content
100%

Mouse follower

✓ Published1🌍 Public
JJanna Uutela
Last edited Oct 3, 2021
Created on Oct 3, 2021

A yellow-bordered circle follows the mouse cursor across an SVG canvas inside a React application. The visualization updates the circle’s `cx` and `cy` attributes in response to `onMouseMove` events, using React state and the `useState` and `useCallback` hooks. The component renders through `ReactDOM.render`, maintaining a fixed canvas size of 960 by 500 pixels while the circle’s radius stays constant at 30.

AI-generated description

A program that follows your mouse with a circle.

MIT Licensed

Similar vizzes