Skip to main content
100%

Mouse Follower Simple

✓ Published2🌍 Public
SSeekerzero
Last edited Jan 16, 2023
Created on Jan 11, 2023
Forked from D3 Starter

A simple interactive visualization renders a circle that follows the mouse cursor. The circle grows in radius as the user moves the mouse faster, measured via the `event.movementX` and `event.movementY` properties, with its size capped at 100 pixels. The example uses D3 v7's selection and data join methods (`select`, `selectAll`, `join`) to bind SVG elements, updating position and radius on each `mousemove` event. The circle is styled with a transparent fill and a black stroke, demonstrating dynamic SVG updates with D3.

AI-generated description

A mouse finder which the circle will enlarge when the user moves the mouse faster.

MIT Licensed

Similar vizzes