Skip to main content
100%

Fork of Mouse Follower

✓ Published0🌍 Public
Ppete0707
Last edited Nov 14, 2022
Created on Nov 14, 2022
Forked from Mouse Follower

A React-based SVG visualization demonstrates mouse tracking by rendering a filled circle that follows the cursor across a 960 by 500 viewport. The app uses React’s `useState` and `useCallback` hooks to store and update the mouse position on every `mousemove` event, setting the circle’s `cx` and `cy` attributes accordingly. The circle starts at the canvas center and moves immediately as the pointer travels, with no delay or animation. The implementation relies on React 16.9 and ReactDOM to render the SVG element directly into the DOM.

AI-generated description

A program that follows your mouse with a circle.

MIT Licensed

Similar vizzes