Ion-scroll width

I’m having some trouble understanding how ion-scroll knows how far it allows the underlying content to scroll.

Does it calculate the width of the content that’s in it and only allows that width to be transformed?

I dug around in the ionicScroll directive but didn’t find anywhere that Ionic is calculating anything. I think it is just the browser/CSS determining width based on content.

1 Like

Thanks for digging into this @Calendee.

I’m noticing that in some cases ion-scroll defines a width and height to scroll in that is bigger than the content that is in it. I’m still researching a bit more when this happens, I’ll report back once I know more.

I second this. I have the scrolling setup horizontally and it keeps going off the page when you scroll to the end.

I’m not quite sure what you mean there. Have you looked at the solution in this post to see if it helps? Horizontal button bar scroller