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

Improve UX by showing a hint if useHitTest returns negative #276

Open
ThorstenBux opened this issue May 30, 2023 · 0 comments
Open

Improve UX by showing a hint if useHitTest returns negative #276

ThorstenBux opened this issue May 30, 2023 · 0 comments
Labels
enhancement New feature or request

Comments

@ThorstenBux
Copy link

Hi,

I've successfully integrated react-xr and I love it. One thing I'd like to improve is adding feedback whenever useHitTest returns negative.
In the current implementation of the hook, the callback won't be called if there isn't a hit. For an initial state that would be fine if I only set a state to scanning until the useHitTest hook is called. However, even after a successful hit result. It can happen that later hitTests fail. In that case, I wouldn't get a callback with the current implementation.
For better UX I propose adding an else case to return an empty (undefined or null) hit property.

See PR #275

@CodyJasonBennett CodyJasonBennett added the enhancement New feature or request label Jul 2, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants