Skip to content
/ dingus Public

🎤 dingus listens to and emits presentation related keyboard events

License

Notifications You must be signed in to change notification settings

mikker/dingus

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

23 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation


dingus

dingus listens to and emits presentation related keyboard events eg. [<-], [->], [space] or the buttons on one of those wireless presenter dinguses.

See also MAXIMUM OVERBUSINESS – a tool to build presentations in React

Usage

var Dingus = require('dingus')
var dingus = new Dingus({ preventDefault: true });

// Listen to specific events (PREV, NEXT, START_STOP, BLANK_SCREEN)
dingus.on(Dingus.PREV, function(event, eventName) {
  // err'body to the left
});

// Or listen to all of them
dingus.on('*', cb);

// remove it again with
dingus.off('*', cb);

function cb(event, eventName) {
  // event.preventDefault() etc, etc
  // eventName === Dingus.PREV etc, etc
}

// remove `keydown` listener from window
dingus.destroy();

License

MIT

About

🎤 dingus listens to and emits presentation related keyboard events

Resources

License

Stars

Watchers

Forks

Packages