npm

is-printable-keycode

1.0.3 • Public • Published

is-printable-keycode

Detect if keycode is a width affecting character (including spaces and deletion)

npm install is-printable-keycode
import isPrintableKeycode from 'is-printable-keycode';

input.addEventListener('keydown', (e) => {
    if (isPrintableKeycode(e.keyCode)) {
        // do something
    }
}, false);

Readme

Keywords

none

Package Sidebar

Install

npm i is-printable-keycode

Weekly Downloads

668

Version

1.0.3

License

MIT

Unpacked Size

3.08 kB

Total Files

6

Last publish

Collaborators

  • mynamesleon