Fork of Mouse Follower
✓ Published0🌍 Public
An interactive React application renders an SVG circle that tracks the mouse cursor across a 960×500 viewport. The component uses React’s `useState` and `useCallback` hooks to update the circle’s `cx` and `cy` attributes on every `onMouseMove` event, reading coordinates from `clientX` and `clientY`. The circle has a fixed radius of 30 pixels and starts at the viewport’s center. This minimal example demonstrates state-driven SVG positioning with React and ReactDOM.
AI-generated descriptionA program that follows your mouse with a circle.
MIT Licensed