GoogleChromeLabs / GoogleChromeLabs/quicklink
Avoid Triggering Requests while offline
Open
- Dominant language
- JavaScript
- Stars
- 11.3k
- Forks
- 429
- PR merge metrics
- No merged PRs in 30d
Description
QuickLink should avoid triggering Network requests when the device is offline.
It should be relatively easy to fix this by adding this code in the `checkConnection` function.
```
if("onLine" in navigator && !navigator.onLine) {
return new Error('Device is offline');
}
```
Contributor guide
Assessment
This issue has not been assessed yet.