The screen recording/screen sharing API can be used for this but security is the reason you have to give explicit permission to the site before it can do this.
There was also that asteroids game / captcha where links were white/black squares and your goal was to click all the black ones. Of course, clicking a square revealed that you knew the square was black, which meant the URL under it was in your history.