Disabling overscroll in Ionic apps

Disabling overscroll/pull to refresh in Ionic 2 apps

Posted on March 21, 2018

Tags:

Ionic

Ionic doesn’t seem to provide a way to disable overscroll in their apps. They do provide a no-bounce attribute you can add to the ion-content tag but this only disables the pull/overscroll if the page content fits with the screen.

The only way I’ve found to disable this is to use the ion-scroll tag within ion-content and disable the parent scroll with CSS.

<ion-header>
</ion-header>
<ion-content>
    <ion-scroll scrollY="true">
    </ion-Scroll>
</ion-content>
.scroll-content {
    overflow-y: hidden;
}

ion-scroll {
    height: 100%;
}