Detecting iOS scroll shortage in Modernizr?

The way iOS handles the onscroll event is described here . Basically, instead of sending multiple onscroll events when scrolling a page / element, it dispatches one onscroll event after the page / element has stopped scrolling.

This creates various problems when writing a dynamic website, and backups are required to fix it.

My question is, is there a Modernizr way to use this “feature flaw”. Another way to deal with it would be to determine which device is being used, which is actually not perfect (the future is iOS 7 comes along and suddenly supports it for all devices, and my site still displays a backup).

+4
source share
1 answer

It is simply impossible to detect at this stage. See: https://github.com/Modernizr/Modernizr/wiki/Undetectables

whether the scroll wheel event occurs from a continuous device, such as a trackpad or magic mouse, or from a traditional scroll wheel (in a webkit).

+1
source

Source: https://habr.com/ru/post/1441510/


All Articles