Skip to main content
🌍 Public

Share visualization

Send this visualization to others.

A circle to follow the mouse

Public visualization

Viewing a saved revision (read-only)

b529b1767ebe4e7cbe99b5697563ee3a

A circle to follow the mouse

0 stars1🌍 Public
FFlorian Kotthoff
Last edited Aug 30, 2021
Created on Aug 30, 2021

A yellow circle follows the mouse cursor across a 960x500 SVG canvas. The React app uses the `useState` hook to track mouse coordinates and `useCallback` to handle mouse movement events, updating the circle's `cx` and `cy` attributes. The SVG is rendered via ReactDOM, with the circle's position initialized to the canvas center.

AI-generated description

A circle that follows the mouse.