loading...

Discussion on: Screen Recording in 10 lines of Vanilla JS

Collapse
sebastianstamm profile image
Sebastian Stamm Author

Not in a video stream. The closest thing you could do is periodically get a snapshot of the current DOM with something like document.body.innerHTML and send it to your server. You could then reconstruct the site based on this HTML.

If you want mouse cursor positions too, you would need a global mousemove handler that tracks the cursor position and also send it to your server.

Of course this only works on your own page. Recording another tab or even window this way without the users consent is fortunately not possible :)