Skip to main content
100%

Fork of Mouse Follower

✓ Published0🌍 Public
NNicolás Troncoso
Last edited Apr 1, 2021
Created on Apr 1, 2021
Forked from Mouse Follower

A circle follows the mouse cursor across an SVG canvas, with its position updating in real time based on the pointer's coordinates. The React component uses the `useState` and `useCallback` hooks to manage and optimize the mouse position state, while the `onMouseMove` event handler captures the cursor's `clientX` and `clientY` values. The visualization is rendered through ReactDOM, which mounts the SVG element into the HTML body, with the circle's center point and radius defined as constants within the code.

AI-generated description

A program that follows your mouse with a circle.

MIT Licensed

Similar vizzes