Skip to main content

All Questions

12 votes
2 answers
8k views

Document visibilitychange versus window blur/focus, what is the difference, when to use which?

In ECMAscript (=Javascript) there are two ways to check if the user is away from your page or not. You can either listen for a "visibilitychange" event on the document or you can listen for "blur" and ...
TheNightwalker's user avatar