question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

bug: scroll not working ios device in ionic 4

See original GitHub issue

scroll is disabled in ios when I put ion-router-outlet inside ion-content. Here is my code

<ion-header >
  <ion-toolbar >
    <ion-avatar>
      
    </ion-avatar>
    <ion-buttons slot="end">
      <ion-button class="default" routerLink='/nurse/tabs/notification'>
        <ion-icon name="notifications"></ion-icon>
        <span class="count notifications" >{{api.notificationCount}}</span>
      </ion-button>
      <ion-menu-button></ion-menu-button>
    </ion-buttons>
  </ion-toolbar>
  <ion-toolbar>
    <div class="segmentBtns">
      <ion-button color="light" routerLink="/nurse/tabs/myshifts/upcoming" routerLinkActive #upc="routerLinkActive"
        [fill]="(upc.isActive)?'solid':'outline'" rla.isActive>Upcoming</ion-button>
      <ion-button color="light" routerLinkActive #comp="routerLinkActive" [fill]="(comp.isActive)?'solid':'outline'"
        routerLink="/nurse/tabs/myshifts/completed">Completed</ion-button>
    </div>
  </ion-toolbar>
</ion-header>
<ion-content>
  <ion-split-pane contentId="myshifts">
    <ion-router-outlet id="myshifts"></ion-router-outlet>
  </ion-split-pane>
</ion-content>

And my module.ts file contains this


import { NgModule } from '@angular/core';
import { CommonModule } from '@angular/common';
import { FormsModule } from '@angular/forms';
import { Routes, RouterModule } from '@angular/router';

import { IonicModule } from '@ionic/angular';
import { SkeltonHeaderPageModule } from '../../directives/skelton/skelton-header/skelton-header.module';
import { SkeltonListSinglePageModule } from '../../directives/skelton/skelton-list-single/skelton-list-single.module';

import { MyshiftsPage } from './myshifts.page';

const routes: Routes = [
  {
    path: '',
    component: MyshiftsPage,
    children: [
          {
            path: 'upcoming',
            loadChildren: './upcoming/upcoming.module#UpcomingPageModule'
          },
          {
            path: 'completed',
            loadChildren: './completed/completed.module#CompletedPageModule'
          },
          {
            path: '',
            redirectTo: 'upcoming',
            pathMatch: 'full'
          }
        ]
  }
];

@NgModule({
  imports: [
    CommonModule,
    FormsModule,
    IonicModule,
    RouterModule.forChild(routes),
    SkeltonHeaderPageModule,
    SkeltonListSinglePageModule
  ],
  declarations: [MyshiftsPage]
})
export class MyshiftsPageModule {}

Any help would be much appreciated.

Bug Report

Ionic version:

[x] 4.x

Current behavior:

Expected behavior:

Steps to reproduce:

Related code:

insert short code snippets here

Issue Analytics

  • State:closed
  • Created 4 years ago
  • Comments:7 (3 by maintainers)

github_iconTop GitHub Comments

2reactions
liamdebeasicommented, May 16, 2019

Hi there,

Thanks for the follow up. I was able to resolve the issue by removing the swipeleft event binding on ion-content in upcoming.page.html. HammerJS can sometimes interfere with scrolling events, so additional configuration may be required.

I am going to close this as this is not an Ionic issue.

For further helping debugging your code, feel free to post on our forum or our slack.

Thanks!

1reaction
dominicg666commented, May 17, 2019

@liamdebeasi Thank you , It’s working 💯

Read more comments on GitHub >

github_iconTop Results From Across the Web

bug: scroll not working ios device in ionic 4 #18273 - GitHub
Hi there,. Thanks for the follow up. I was able to resolve the issue by removing the swipeleft event binding on ion-content in...
Read more >
PWA scrolling issue on iOS - Ionic 4
Hi, I'm still facing the scroll issue on iOS which cause interface to freeze for few seconds and make user experience quite bad....
Read more >
Ionic 4 *ngFor does not scroll properly in iOS - Stack Overflow
Thanks for the tip, I tried it. That doesn't work. The issue is the content size to be scrolled isn't updating. So it's...
Read more >
The 9 Most Common Mistakes That Ionic Developers Make
However, over time, the best practices and tooling for Ionic have not ... Build your app and install it on your device by...
Read more >
Infinite scrolling issue on iOS only. : r/ionic - Reddit
I just started to use infinite scroll for a messaging API, and I ran into an issue where if you scroll just right...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found