Skip to content
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

onKeyDown is not registered until component is clicked. #2662

Open
1 task done
ali-sao opened this issue May 3, 2024 · 0 comments
Open
1 task done

onKeyDown is not registered until component is clicked. #2662

ali-sao opened this issue May 3, 2024 · 0 comments
Labels

Comments

@ali-sao
Copy link

ali-sao commented May 3, 2024

Is there an existing issue for this?

  • I have searched the existing issues

Describe the issue

I am unable to register the onKeyDown unless the component is being clicked.

Expected behavior

I am expecting both event handlers to be working simultaneously

Steps to reproduce

  • Use the official template
  • open the console hit any key
  • Try to click on the pressable component.
  • Hit any key again to see the onKeyDown is logging the keycode successfully/

Test case

https://codesandbox.io/p/devbox/react-native-web-examples-4kq2h4?embed=1&file=%2Fpages%2Fpressable%2Findex.js

Additional comments

No response

@ali-sao ali-sao added the bug label May 3, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

1 participant