navigator.online on it's own for checking if a user is really online is not working. It only lets you know if there is network access, which isn't the same as "connected to the internet". So basically, it is useless, unless you application works in a closed off network or something....
I've left a link to some of the issues with navigator.online in the article. Definitely not a good solution alone. The event listeners are the real magic for checking when people are using apps on the move.
For further actions, you may consider blocking this person and/or reporting abuse
We're a place where coders share, stay up-to-date and grow their careers.
navigator.online
on it's own for checking if a user is really online is not working. It only lets you know if there is network access, which isn't the same as "connected to the internet". So basically, it is useless, unless you application works in a closed off network or something....I've left a link to some of the issues with
navigator.online
in the article. Definitely not a good solution alone. The event listeners are the real magic for checking when people are using apps on the move.