Fork of Mouse Follower
✓ Published0🌍 Public
A circle follows the mouse cursor within an SVG canvas, updating its position in real-time as the pointer moves. The visualization uses React with a `useState` hook to track the mouse coordinates and a `useCallback` handler to update the circle’s `cx` and `cy` attributes. The rendering is done via SVG elements, with the circle initialized at the center of the 960×500 viewport. The code references React and ReactDOM, and uses the `onMouseMove` event to capture the cursor’s `clientX` and `clientY` properties.
AI-generated descriptionA program that follows your mouse with a circle.
MIT Licensed