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

how to listen to Key events #308

Open
grimace opened this issue Jan 27, 2018 · 0 comments
Open

how to listen to Key events #308

grimace opened this issue Jan 27, 2018 · 0 comments

Comments

@grimace
Copy link

grimace commented Jan 27, 2018

I've tried adding an eventListener to document ( which has worked in a other keyboard plugins ), like this:

document.addEventListener('keydown', (key) => {this.onKeyPress(key)} );

but when I get the event call back, all I get is:

{"isTrusted":true}"

Is there a way to listen for keydown or keyup?

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant