react-shortcuts
react-shortcuts copied to clipboard
IE11: Exceptions thrown due to missing CustomEvent
CustomEvent is not available in IE11 which causes the Shortcuts component to malfunction by throwing an unhandled exception on each keypress, leading to a massive slowdown when typing (as well as the shortcuts not working, of course). 😉
We were able to remedy the problem by supplying the polyfill for IE described here: https://developer.mozilla.org/en-US/docs/Web/API/CustomEvent/CustomEvent
There is also an npm package that should fix this issue easily (untested): https://github.com/krambuhl/custom-event-polyfill
Could you include the polyfill for the next release? Thanks!
@forum-is Thanks for pointing out this issue. I'm thinking if we should include the polyfill directly in or just highlight the problem in the README.
We'd very much prefer including the polyfill as it is tiny and avoids the nasty exceptions in IE11.