Skip to content

perf: ion-slides crash on iOS with memory error #3722

@neilgoldman

Description

@neilgoldman

Type: perf

Platform: ios 8 webview

Ionic crashes on iOS with a memory exception when you have more than just a few ion-slides in an ion-slide-box. Confirmed in both the phone's browser and 'native hybrid' apps on the device. So far I've only been able to test it on several iPhone 5S and iPhone 6 with iOS >= 8.0.0.

I've made this test to reproduce it and had most of my office run it. You can open it in Safari, or try building it 'natively'. Just tap the button to add more slides until it crashes.

http://play.ionic.io/m/229b294cf005

Most people have their browser crash at around 30 slides, or around 80 slides. But even on low-end android devices, using the stock browser, we can get into the hundreds without crashing.

The actual content of the slides doesn't seem to matter. It seems to crash around the same threshold with slides containing lots of images, or slides just containing "

foo

"

Edit:
Here's an additional Ionic playground to show that it's not just ng-repeat causing the issue. It simply has 90 elements of

foo

inside the slide-box. Just tried it on my iPad Mini 3 and it perpetually crashes the page until Safari stops trying.
http://play.ionic.io/m/77d031c7757b

Last edit:
I think the issue is CSS transforms? Disabling transforms on .slider-slide solves it for me.
http://play.ionic.io/m/0080892702e9

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions