Y
Hacker News
new
|
ask
|
show
|
jobs
by
eclipticplane
4769 days ago
Regarding the multiple tab issue, you can use the Page Visibility API [1] to determine if the page is still visible before firing the timeout event. It's a pretty handy API for other things, too.
[1]
https://developer.mozilla.org/en-US/docs/Web/Guide/User_expe...