Skip to main content
100%

Mouse Follower

✓ Published1🌍 Public
TtrwMK
Last edited Oct 10, 2022
Created on Oct 10, 2022

This example shows a single circle that follows the mouse cursor across the full browser window. The circle’s position updates live through React state, using the `clientX` and `clientY` values from the `onMouseMove` event on an SVG element. The code renders the circle as an SVG `<circle>` with React 16.9, and the state hook `useState` manages the cursor coordinates. The visualization demonstrates a simple interactive mapping between pointer movement and SVG shape placement.

AI-generated description

A Program that follows your mouse with a circle

MIT Licensed

Similar vizzes