Skip to main content
🌍 Public

Share visualization

Send this visualization to others.

Loading data in React

Public visualization

Loading data in React

0 stars1🌍 Public
PPaulo Dandrea
Last edited Jan 20, 2022
Created on Jan 20, 2022
Forked from Mouse Follower

A React application demonstrates mouse tracking by rendering a single SVG circle that follows the cursor. The component uses React's `useState` hook to store the mouse position and a `useCallback` hook to handle the `onMouseMove` event, updating the circle's `cx` and `cy` attributes. The visualization renders through ReactDOM into an SVG element with a fixed 960 by 500 viewport, showing how React state drives interactive SVG updates without any external data loading or D3 dependencies.

AI-generated description

React Starter code.

Comments

Sign in to join the discussion.

MIT Licensed