Skip to main content
🌍 Public

Share visualization

Send this visualization to others.

Mouse Follower

Public visualization

Viewing a saved revision (read-only)

73cf60ac576b4517a276aa398c121bda

Mouse Follower

0 stars1🌍 Public
Aalexandermodell
Last edited Feb 21, 2022
Created on Feb 21, 2022

A circle tracks the mouse cursor across a full-screen SVG canvas, redrawing its position in real time. The visualization demonstrates state-driven rendering with React, using the `useState` hook to store cursor coordinates and `onMouseMove` to capture events. A React component updates the circle’s `cx` and `cy` attributes dynamically, while the SVG viewport matches the browser window’s dimensions. The example uses the React and ReactDOM libraries to manage the interactive element without any external data source.

AI-generated description

A program which follows your mouse.