Skip to content

kt3k/arrowkeys

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

23 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

arrowkeys v0.2.0

Events for arrow keys (→←↑↓). Depends on jquery.

Usage

Load script:

<script src="path/to/jquery.js"></script>
<script src="path/to/arrowkeys.js"></script>

To bind arrowkey events:

$(document).arrowkeys();

Handle each key event:

$(document)
    .on('upkey', function () {})
    .on('downkey', function () {})
    .on('leftkey', function () {})
    .on('rightkey', function () {});

To unbind the events:

$(document).arrowkeysUnbind();

License

MIT

About

Arrowkey events in browser

Resources

License

Stars

Watchers

Forks

Packages

No packages published