-
Notifications
You must be signed in to change notification settings - Fork 12
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Compatibility with React 15.4 #11
Comments
I'm not actively using this module at the moment, so unlikely to have time to delve into this. I'll happily take a PR though. One of the original goals with this lib was to get a React-wrapped event object rather than the standard browser event object - which is why I had to reach into the internals. This might not be as important these days. |
It may only require to replace |
What is the reason why my PR have been failed? https://travis-ci.org/glenjamin/react-hotkey/builds/176617307 |
Should be resolved in 0.7.0 |
This will do as a quick fix, but there is absolutely no guarantee that a future change to React internals won't unexpectedly break it again. It might be a good idea to look into a more permanent solution or at least update the README to inform users of this library that it relies on an unstable technique and may unexpectedly break builds. I can provide a PR for the README if needed. |
PR for the readme to warn about internals usage sounds good. React doesn't expose the synthetic events as a supported API, so there's no better way to get the same effect. See facebook/react#285 for more details about this. I have some vague ideas about a different way to approach hotkeys, using a child component and mousetrap, but nothing I'm likely to work on or publish any time soon. |
This line in index.js fails with React 15.4.0:
From the React 15.4.0 blog post:
The text was updated successfully, but these errors were encountered: