Skip to main content
🌍 Public

Share visualization

Send this visualization to others.

Mouse Follower

Public visualization

Viewing a saved revision (read-only)

1d2aed8b3e014575889ca1dead9e549e

Mouse Follower

0 stars1🌍 Public
Ppytorchgirl
Last edited Dec 4, 2021
Created on Dec 4, 2021

A circle follows the mouse cursor across an SVG canvas that fills the browser window, updating its position in real time. The visualization demonstrates React state management with the `useState` hook, tracking mouse coordinates via an `onMouseMove` event handler on the SVG element. React and ReactDOM render the circle at the cursor's `clientX` and `clientY` positions, and the initial state places the circle at the center of the viewport before interaction begins.

AI-generated description

A Program that follows your mouse with a circle.