Skip to main content
🌍 Public

Share visualization

Send this visualization to others.

Fork of Following Circle

Public visualization

Viewing a saved revision (read-only)

43eb1253677949c0b7123b152e9d15ea

Fork of Following Circle

0 stars1🌍 Public
KKian Candelario
Last edited Jul 3, 2022
Created on Jul 2, 2022
Forked from Hello VizHub

This example displays a single circle that follows the cursor across an SVG canvas, with its center updating to the mouse’s current position. Built with React and D3 v7, it uses React’s `useState` and `useCallback` hooks to manage mouse coordinates and re-render the circle on every `mousemove` event. The graphic is rendered as an SVG `<circle>` element, with the initial position set to the center of the 960×500 viewport.

AI-generated description

A circle that follows the cursor.