-
Notifications
You must be signed in to change notification settings - Fork 25
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
Uncaught TypeError: Cannot read property 'getBoundingClientRect' of null #6
Comments
Hi @hazirmagron I'm guessing you downloaded the package from npm? If this is true, the problem you are talking about was fixed in #1 but was never published to npm, current version in npm is the original version v0.0.1, a lot has changed since then. Let me know if I'm correct. Either way we have to publish a new version of this module to npm. @jaredpalmer I vote for bumping up from 0.x to 1.0.0 due to the latest updates and then publish. |
Hi @pgarciacamou! Yes, you're very much right. I did install it through npm. Makes sense how you communicated on the DOC then. Yes, update the npm version please. It is a very messy and annoying bug. |
@hazirmagron so, I had an idea (sorry in advance 🙉) I honestly believe that @jaredpalmer is super busy with react itself so, what I would suggest is to fork this repo and install from git. This is what you would need to do:
npm install --save username/repo#branch-name
# like:
npm install --save pgarciacamou/react-simple-infinite-scroll#temp-fork Note that I haven't tried this and this is only a temporary solution, but Jared hasn't answered my messages so that is the best I've got. Let me know if you have any questions. |
@pgarciacamou that worked for me, thanks 😄 |
If anyone's interested, I published the fixed version of this package here: https://www.npmjs.com/package/react-simple-infinite-scroll-patched |
@iest I tried your patch and I'm getting duplicate key issues, meaning that my queries aren't being throttled. I wasn't having this issue with v.0.0.1. Any ideas? |
It's because v0.0.2 includes this PR was merged in, but it's buggy. |
Following the 'full example' I get this error once I scroll while the component where react-simple-infinite-scroll lies has been unmount.
I assume the error has to do with not removing the event listener to scroll - which should be done once the component containing the infinite scroll is unmounted. This seems to be coupled with how the sentinel object is handled, which is mentioned in the DOCS. It is unclear how it should be used, however.
This, to me, seems like a DOC issue if anything. I think this issue has been accounted for. It is just not properly communicated in the DOCS.
The text was updated successfully, but these errors were encountered: