live-cursors — viewport space

Open this page in a second window of the same browser profile, put the two side by side and move the mouse. Cursors travel over BroadcastChannel, so there is no server involved — but that also draws the boundary: a different browser, another Chrome profile or an incognito window will never see them. For cursors across browsers there is the WebSocket demo.

A second tab is not enough either: a tab going to the background announces a leave, so its cursor is removed right away.

Coordinates are normalized against the window, so a cursor sits at the same screen position for everyone regardless of window size or scroll offset.