Sign in
Log inSign up

How to detect tab/browser close event on mobile safari?

Rajkumar's photo
Rajkumar
·Oct 31, 2018

I tried looking everywhere. For the past few days, with dreaded eyes, I searched every other place in web, but no where I get anything which remotely close to what I am looking for.

All I know is that beforeunload doesn't work in Mobil Safari.

Why I need it? I am developing a solution where if user try to open the same app. in another tab, system will alert the user and not let him login. This solution uses localStorage and works good so far in every where except iPad Safari browser. Is there anyone here faced the same issue and got any solution? Help out a tired, weary fellow guys!