3.1.0 • Published 7 months ago

hotkey-mapper v3.1.0

Weekly downloads
-
License
MIT
Repository
github
Last release
7 months ago

Hotkey-mapper

a simply frontend hotkey-mapper

Usage

import hotkeyMapper from 'hotkey-mapper'
const unloadHotkeyMaps = hotkeyMapper({
    "alt+i": () => console.log('init-task'),
    "alt+t": () => console.log('tag'),
    "alt+n": () => console.log('next-task'),
    "alt+u": () => console.log('user'),
    "ctrl+alt+c": () => console.log('code-action'),
});
await new Promise(r => setTimeout(r, 60e3)) // wait 1 min
unloadHotkeyMaps()

or import by script

<script src="https://cdn.jsdelivr.net/npm/hotkey-mapper/dist/index.umd.js" > </script>
<script>
const hotkeyMapper = hotkeyMapper.hotkeyMapper
const unloadHotkeyMaps = hotkeyMapper({
    "alt+i": () => console.log('init-task'),
    "alt+t": () => console.log('tag'),
    "alt+n": () => console.log('next-task'),
    "alt+u": () => console.log('user'),
    "ctrl+alt+c": () => console.log('code-action'),
});
</script>

About

License

MIT

Author

Author: snomiao snomiao@gmail.com Website: snomiao.com

Sponsors

  • None yet.

Claim your sponsorship by donating snomiao <Email: snomiao@gmail.com>

Contribute

The main repo is in here, any issue and PR's welcome.

3.1.0

7 months ago

3.0.4

1 year ago

3.0.3

1 year ago

3.0.2

1 year ago

3.0.1

1 year ago

3.0.8

1 year ago

3.0.7

1 year ago

3.0.5

1 year ago

3.0.0

1 year ago

2.1.4

1 year ago

2.1.5

1 year ago

1.1.0

2 years ago

2.1.2

2 years ago

2.1.1

2 years ago

2.1.3

2 years ago

2.1.0

2 years ago

2.0.2

2 years ago

1.2.6

2 years ago

1.2.5

2 years ago

2.0.0

2 years ago

1.2.0

3 years ago

1.1.240

3 years ago

1.2.4

3 years ago

1.2.1

3 years ago

1.0.1

3 years ago

1.0.0

3 years ago