Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

navigator.onLine does not work #120

Open
flecce opened this issue Feb 12, 2019 · 1 comment
Open

navigator.onLine does not work #120

flecce opened this issue Feb 12, 2019 · 1 comment

Comments

@flecce
Copy link

flecce commented Feb 12, 2019

Hi,

the navigator.onLine statement does not work.
Also the event listener on connection status does not work.

window.addEventListener('online', () => { alert(true); });
window.addEventListener('offline', () => { alert(false); });

Do you know the issue?
Thanks in advance
Bye

@flecce flecce closed this as completed Feb 19, 2019
@flecce flecce reopened this Feb 19, 2019
@candidodmv
Copy link

candidodmv commented Nov 18, 2019

It's apper that you are misunderstood of these events:

https://developer.mozilla.org/pt-BR/docs/Web/API/NavigatorOnLine/Online_and_offline_events

Offiline:
This property is updated when the user enters "Offline Mode" by clicking on the corresponding menu item (File -> Offline Mode).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants