Skip to main content
100%

Circle Follower

✓ Published1🌍 Public
JJenna Hamza
Last edited Dec 29, 2022
Created on Dec 29, 2022
Forked from Happy Face

A circle follows the mouse cursor across an SVG canvas, updating its position in real time as the pointer moves. Built with React and d3.v7, the app uses React’s `useState` and `useCallback` hooks to track and update the mouse coordinates on every `onMouseMove` event, rendering a single `<circle>` element with a radius of 30 pixels. The example relies on SVG rendering within a 960×500 viewport, with the initial circle centered at the midpoint of the canvas.

AI-generated description

A bare minimum HTML page.

MIT Licensed

Similar vizzes