Mouse follower
✓ Published1🌍 Public
A React application renders a single SVG circle that follows the mouse cursor as it moves across the full-window viewport. The component uses the `useState` and `useCallback` hooks to track the cursor’s `clientX` and `clientY` coordinates, updating the circle’s `cx` and `cy` attributes on every `onMouseMove` event. The initial position is centered based on `window.innerWidth` and `window.innerHeight`. This simple interactive example demonstrates real-time state-driven SVG updates without any external data sources or animation libraries.
AI-generated descriptionApplication that follows your mouse.
MIT Licensed