Skip to main content
🌍 Public

Share visualization

Send this visualization to others.

Fork of Mouse Follower

Public visualization

Viewing a saved revision (read-only)

3e899bc2ef1541c39795c210c824baa8

Fork of Mouse Follower

0 stars0🌍 Public
Ssunole896@yahoo.com
Last edited Feb 27, 2023
Created on Feb 27, 2023
Forked from Mouse Follower

A circle follows the mouse cursor across a full-viewport SVG. The example demonstrates unidirectional data flow: mouse events trigger a state update, which then re-renders the visualization. Built with D3 v7, it uses `select`, `join`, and event handlers to bind the circle’s `cx` and `cy` attributes to the current cursor position. The state is managed externally and passed into the `viz` function, with `setState` triggering a re-render on each mouse move. No external data source is used; the interaction is purely based on user input.

AI-generated description

A circle that follows the mouse using unidirectional data flow.