Coding With Fun
Home Docker Django Node.js Articles Python pip guide FAQ Policy

jQuery Mobile Scroll event


May 21, 2021 jQuery Mobile


Table of contents


jQuery Mobile Rolling Event

jQuery Mobile provides scrolling events to scroll the screen.

jQuery Mobile provides two types of rolling events: trigger at the beginning of the scroll and trigger at the end of scrolling.


jQuery Mobile Roll Start (Scrollstart)

The scrollstart event is triggered when the user starts scrolling the page:

$(document).on("scrollstart",function(){
alert("Started scrolling!");
});

Try it out . . .

jQuery Mobile Scroll event Note: The iOS device locks the DOM action when the screen is rolled, which means that nothing can be changed when the user scrolls the screen. However, the jQuery team is looking for a solution for this.


jQuery Mobile Roll End (Scrollstop)

The scrollstop event is triggered when the user stops scrolling the page:

$(document).on("scrollstop",function(){
alert("Stopped scrolling!");
});

Try it out . . .
In the next section, you'll learn about the jQuery Mobile direction change event!