DEV Community

Discussion on: Detect Internet Connection Status In Browser

bibekkakati profile image
Bibek Author

Polling is a good way, but to use it as an alternative to the listeners we will have to poll very frequently.
I prefer to use the listeners as those side cases are not so impacting. After a false-positive result, if we send a valid request and it fails, we will get to know about the false-positive status. At last, it depends on the application and it's working.