Skip to main content
100%

Mouse Follower

✓ Published1🌍 Public
SSonja Ek
Last edited May 29, 2021
Created on May 29, 2021
Forked from Hello VizHub

This interactive visualization displays a single circle that follows the mouse cursor across an SVG canvas. Built with React, the example uses the `useState` hook to track the cursor's `clientX` and `clientY` coordinates within an `onMouseMove` event handler on the `<svg>` element. The circle's center position updates reactively via `setMousePosition`, rendering in real time as the user moves the mouse. The visualization demonstrates a simple, responsive interaction pattern using React's declarative state management and SVG rendering.

AI-generated description

A program that follows your mouse with a circle.

MIT Licensed

Similar vizzes