5

After I tested affix on my website on iPad I find out that it is not working properly and I goggled that it is problem with iOS https://github.com/twbs/bootstrap/issues/11560 and currently there is no easy solution for that.

iOS just has problems with calculating fixed position as you scroll. Basically you don't get an updated fixed position until a slight delay after you stop scrolling

Is there anything I can do to make it work, may be some one already done some work around?

Sergino
  • 10,128
  • 30
  • 98
  • 159
  • If you read the entire thread there's no answer to make it work. – Christina Dec 25 '13 at 17:32
  • yes I did, but just wondering may be some one outside that thread, here on SO, have any opinions on that. – Sergino Dec 25 '13 at 22:35
  • Change the title to "fixed position delayed on IOS" or something. If you read that thread you'll see that @fat (the programmer for Bootstrap's scripts) and the person behind WayPoints (one of the most popular affix scripts) have found no solutions because it's an IOS native behavior. You'll notice that if the section is position:fixed on load, that this doesn't happen but if the affix is triggered by a user action (scroll) the delay happens. – Christina Dec 26 '13 at 01:54

1 Answers1

9

This, sometimes, made the trick for me.

    .youraffixelement {
       -webkit-transform: translate3d(0, 0, 0);
       transform: translate3d(0, 0, 0);
    }

It enables hardware acceleration on iOs devices, and the scroll position is calculated faster.

Vicent Ibáñez
  • 439
  • 1
  • 6
  • 10