Part 9—Create dedicated mobile website

44 Page transition

By default, all page transitions are fading effect. We can control individual link transition by adding data-transition attribute to the a href. For example, the following link would display the target page by sliding the content in.

<a data-role='button' data-transition='slide' href='#page-2'>Slide</a>

Or we can configure the default page transition via JavaScript:

$.mobile.defaultPageTransition = 'slide';

License

Page transition Copyright © by makzan. All Rights Reserved.

Share This Book

Notice: 2nd edition update is work-in-progress. See update logs for details.