-
Notifications
You must be signed in to change notification settings - Fork 88
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
Cannot read property 'getBoundingClientRect' of null #43
Comments
I'm having the same problem. I tried wrapping my components in Edit: I managed to solve it - in my case it was caused by a child of |
I'm having the same problem. In my case, I use the functional component as the child of It seems that it needs |
It happened to me too and the problem in my case was that the child of the ScrollableAnchor had a react ref function. |
I'm having this issue at the moment, I have a component as the |
@TrebuhD thx for the hint, I used a
After I changed them to a |
That's the correct solution. This package doesn't play nice with either React Fragment or multiple child elements. |
Hi i get the same /similiar error any workaround? scroll.js:14 Uncaught TypeError: Cannot read property 'getBoundingClientRect' of null |
Wrap the scrollcontent element which you are targeting with <></> with this. |
My entire app is this:
I get this error after a scroll stops:
(context: I just want something that changes the URL of the page to have a fragment corresponding with whatever picture is currently in the viewport, so that if the link is shared, the browser will scroll to that specific picture. Shouldn't be hard, right?)
The text was updated successfully, but these errors were encountered: