Open justin-betty opened 1 year ago
Hello,
When adding options the callback is not working any more in React 18.2.0
React 18.2.0
Adding it like this: hotkeys('esc', () => console.log('test')); works fine.
hotkeys('esc', () => console.log('test'));
Adding it like this: hotkeys('esc', 'scope', () => console.log('test')); or hotkeys('esc', { scope: 'scope' }, () => console.log('test')); doesn't work.
hotkeys('esc', 'scope', () => console.log('test'));
hotkeys('esc', { scope: 'scope' }, () => console.log('test'));
Somehow the callback isn't triggered then
@justin-betty
hotkeys.setScope('scope');
Hello,
When adding options the callback is not working any more in
React 18.2.0
Adding it like this:
hotkeys('esc', () => console.log('test'));
works fine.Adding it like this:
hotkeys('esc', 'scope', () => console.log('test'));
orhotkeys('esc', { scope: 'scope' }, () => console.log('test'));
doesn't work.Somehow the callback isn't triggered then