Parallax scrolling not working on mobile css

后端 未结 1 1755
孤城傲影
孤城傲影 2021-01-13 17:56

My parallax scrolling is not working on mobile devices, both android and iOS. The code works great for desktop but not for mobile, be it any browser. Background images are n

相关标签:
1条回答
  • 2021-01-13 18:38

    Parallax will never work properly on mobile devices - and here is why.

    Mobile browsers are designed to function as efficiently as possible in order to save on battery life. One way that they do that is that they delay JS execution during a scroll event. Symptomatically this will display as the parallax not parallaxing but rather jumping to its new position after scroll completes.

    I recommend disabling all parallax once down to mobile viewport.

    Further reading on this topic: http://developer.telerik.com/featured/scroll-event-change-ios-8-big-deal/

    0 讨论(0)
提交回复
热议问题