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

useScroll is returning null #2267

Open
parasjain10 opened this issue Dec 11, 2024 · 1 comment
Open

useScroll is returning null #2267

parasjain10 opened this issue Dec 11, 2024 · 1 comment
Labels
bug Something isn't working

Comments

@parasjain10
Copy link

parasjain10 commented Dec 11, 2024

  • three version: 0.150.1
  • @react-three/fiber version:8.11.5
  • @react-three/drei version:9.56.28
  • node version: 22.4.1
  • npm (or yarn) version:10.9.0

Problem description:

Relevant code:

const scroll =useScroll();
console.log(scroll); // null

Suggested solution:

@parasjain10 parasjain10 added the bug Something isn't working label Dec 11, 2024
@appeltje-c
Copy link

@parasjain10 are you using the hook in a component wrapped in the ScrollControls / Scroll components?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants