Skip to main content
🌍 Public

Share visualization

Send this visualization to others.

Mouse Follower

Public visualization

Viewing a saved revision (read-only)

01b7e78acf7b4f51af6554f50d8cf5c7

Mouse Follower

0 stars1🌍 Public
TTheOutstandingDinosaur
Last edited Aug 15, 2024
Created on Aug 15, 2024

A single gray circle tracks the user's cursor across the full browser window, moving smoothly to reflect the mouse's current x and y coordinates. Built with React hooks (`useState` and `useCallback`), the application listens for `onMouseMove` events on an SVG element and updates the circle's `cx` and `cy` attributes. The rendering is handled entirely through React's virtual DOM and SVG, with no external data sources or animation libraries involved.

AI-generated description

A programme that follows the mouse