Skip to content
This repository has been archived by the owner on Mar 27, 2019. It is now read-only.

iOS 11.3 (Safari 11.1) Breaks & My Solution #1232

Open
jongmoon opened this issue Apr 30, 2018 · 1 comment
Open

iOS 11.3 (Safari 11.1) Breaks & My Solution #1232

jongmoon opened this issue Apr 30, 2018 · 1 comment

Comments

@jongmoon
Copy link

jongmoon commented Apr 30, 2018

By updating iOS 11.3, iScroll is affected by a Safari 11.1 change.
I think #1231 could be related with this updates.

It is passive mode policy.

https://developer.apple.com/library/content/releasenotes/General/WhatsNewInSafari/Articles/Safari_11_1.html#//apple_ref/doc/uid/TP40014305-CH14-SW2

You can find that

Updated root document touch event listeners to use passive mode improving scrolling performance and reducing crashes

If you use preventDefault option as true(it's default), you would not worry about it. it will work OK.

But If you use preventDefault option as false, you should check touchmove handler (which does e.preventDefault()) on root document have {passive:false} like following.

var myScroll = new IScroll('#wrapper', {
  preventDefault: false
}

// You should check touchmove handler have `passive:false`
document.addEventListener('touchmove', function (e) {e.preventDefault();}, {
  passive: false
});

Is there any solution?

bindToWrapper option is true, passive:false is not needed.

@jongmoon jongmoon changed the title iOS 11.3 (Safari 11.1) Issue & My Solution iOS 11.3 (Safari 11.1) Breaks & My Solution Apr 30, 2018
@Calinas
Copy link

Calinas commented Jul 2, 2018

Hi, thanks. Your solution did work in my case.Saves a lot of trouble and time.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants