From 392f4b44f0e209dc54efd20c82ba125fb733fc58 Mon Sep 17 00:00:00 2001 From: Sarthak Tripathi Date: Wed, 18 Oct 2017 19:11:05 +0530 Subject: [PATCH] Updated online-offline-events.md Added links, removed grammatical error. --- docs/tutorial/online-offline-events.md | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/docs/tutorial/online-offline-events.md b/docs/tutorial/online-offline-events.md index ea80d4d02090..d5399405f7d7 100644 --- a/docs/tutorial/online-offline-events.md +++ b/docs/tutorial/online-offline-events.md @@ -1,7 +1,6 @@ # Online/Offline Event Detection -Online and offline event detection can be implemented in the renderer process -using standard HTML5 NavigatorOnLine API. +[Online and offline event](https://developer.mozilla.org/en-US/docs/Online_and_offline_events) detection can be implemented in the renderer process using [NavigatorOnLine](http://html5index.org/Offline%20-%20NavigatorOnLine.html) attribute, part of standard HTML5 API. The navigator.onLine attribute returns `false` if the user agent will not contact the network when the user follows links or when a script requests a remote page (or knows that such an attempt would fail) i.e. definitely offline (disconnected from the network) and must return `true` otherwise. Since all other conditions return `true`, one has to be mindful of getting false positives, as we cannot assume `true` value necessarily means that Electron can access the internet. Such as in cases where the computer is running a virtualization software that has virtual ethernet adapters that are always “connected.” Therefore, if you really want to determine the internet access status of Electron,