get

getonline

listen to internet connection status

Showing:

Popularity

Downloads/wk

0

Maintenance

No Maintenance Data Available

Package

Dependencies

1

Size (min+gzip)

0.3KB

License

MIT

Type Definitions

Tree-Shakeable

No?

Categories

Readme

getonline

NPM Version Coverage Status Build Status Downloads Dependency Status License

listen to internet connection status

Install

npm i -D getonline

Usage

var Online=require('getonline');
const internet=new Online({timeout:3000}) // default to 3s

internet.on('connected',function(){
      console.log('you are online !');
}) 

internet.on('disconnected',function(){
      console.log('disconnected...');
}) 

API

getonline([options])

options

Type: Object

timeout

Type: number
Default: 5000

Milliseconds interval to check status again.

License

MIT © abdelhak akermi

Rate & Review

Great Documentation0
Easy to Use0
Performant0
Highly Customizable0
Bleeding Edge0
Responsive Maintainers0
Poor Documentation0
Hard to Use0
Slow0
Buggy0
Abandoned0
Unwelcoming Community0
100