Skip to main content
🌍 Public

Share visualization

Send this visualization to others.

Mouse Follower

Public visualization

Viewing a saved revision (read-only)

0eb8af2ebb6c477b8fa33ab9bff3d7d0

Mouse Follower

0 stars1🌍 Public
Iikerson
Last edited Aug 8, 2021
Created on Aug 8, 2021

A circle tracks the mouse cursor in real time across an SVG canvas. The React component uses the `onMouseMove` event to update the circle's center coordinates via the `useState` and `useCallback` hooks. The circle is rendered with SVG, and its position is driven by the client X and Y values from the mouse event. The example demonstrates a simple interactive visualization with React and SVG.

AI-generated description

A program that follows your mouse with a circle.