0

iOS 8+ now supports "real" scroll events in Safari, firing off events continuously rather than after the scroll event is complete. This means that previously used hacks to make scroll-based animations and parallax effects work on touch devices (such as wrapping all the content in a big container that does the actual scrolling) are no longer necessary for Safari in iOS 8+.

Because I'm not a big fan of the scroll hacks, I currently disable non-essential scroll animations on touch devices. I could exclude Safari on iOS 8+ from that check but a better solution would be to test for that feature specifically.

Is there any way to test if a browser fires off scroll events in real time rather than once the scroll gesture is complete?

Sam Hanley
  • 4,707
  • 7
  • 35
  • 63
Yaron
  • 1,867
  • 20
  • 16
  • Because browser JS is single threaded, no browser processes scroll events truly in real time. As long as the previous scroll event is still being processed, no new scroll event can be processed until the former JS thread of execution is done. Perhaps you chose the wrong words to describe what is happening? – jfriend00 Jan 06 '15 at 01:39
  • "*I currently disable non-essential scroll animations on touch devices*" your users are probably very happy with that. ;-) – RobG Jan 06 '15 at 02:34

0 Answers0