Skip to content
This repository has been archived by the owner on Apr 4, 2019. It is now read-only.

yields/status

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

5 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

status

User "active" / "idle" event emitter.

Example

var status = requrie('status');
status.watch();

status('idle', function(){
  console.log('idle!');
});

status('active', function(){
  console.log('active!');
});

Installation

$ component install yields/status

API

status.watch([timeout])

Start watching on mousemove and keyup the default timeout is 1 minute.

status.unwatch()

Stop watching mousemove and keyup.

status(event, fn)

Invoke fn on event.

Todo

  • add tests.

License

MIT

About

user activity emitter, "idle" "active" etc..

Resources

Stars

Watchers

Forks

Packages

No packages published