question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

TypeError: Cannot read property 'offset' of undefined

See original GitHub issue

When scrolling really fast, the following error can always be reproduced.

It appears to be the result of a floating point issue. I was able to reproduce this both on my iPhone and Chrome.

Maybe just parseInt(...)?

Issue Analytics

  • State:closed
  • Created 7 years ago
  • Comments:10 (4 by maintainers)

github_iconTop GitHub Comments

2reactions
JesseChrestlercommented, Apr 19, 2017

For anyone that comes across this, I found that it was because I was passing a decimal value to the scrollToIndex. Math.round or any other like ceil, or floor fixes this issue.

0reactions
wi-skicommented, Sep 18, 2017

Im running into this currently. Very rare. Very frustrated.

Read more comments on GitHub >

github_iconTop Results From Across the Web

TypeError: Cannot read property 'offset' of undefined #246
Hello! You guys! This happens because the page tries to fetch the next nonexistent page, fix by: Base('Training Booked') .select({ fields : [' ......
Read more >
Uncaught TypeError: Cannot read property 'offset' of undefined
I am getting Uncaught TypeError: Cannot read property 'offset' of undefined. Before that i was getting same exception for 'top' from same ...
Read more >
Cannot read property 'offset' of undefined - Airtable Community
Hi, I am trying to load all rows of a base. The code I use is: const airbase = airtable.base('XXXXXXXX').table('someTable') await.
Read more >
TypeError: Cannot read property 'offset' of undefined - jQWidgets
I'm getting the error TypeError: Cannot read property 'offset' of undefined but I don't know why…. My JSON is valid and looks like...
Read more >
TypeError: Cannot read property 'top' of Undefined in JS
To resolve the "Cannot read property 'top' of undefined" error, make sure that the DOM element you're accessing the top property on exists....
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found