Slow page transitions on Android with hardware acceleration on

Alon Gubkin picture Alon Gubkin · Feb 4, 2014 · Viewed 7.3k times · Source

I'm trying to run the ionic-angular-cordova-seed project on Android 4.3.1 with Cordova. One thing I've noticed is that page transitions (for example, clicking on a tab or a list item) are very slow.

I tried to disable hardware acceleration using:

super.appView.setLayerType(WebView.LAYER_TYPE_SOFTWARE, null);

... and it worked perfectly. But then scrolling, side menu sliding and more animations became extremely slow.

I've tried FastClick, it didn't make any difference.

I found this CSS-based solution to the problem, but I'm not familiar enough with Ionic to apply it on it. Any ideas?

Note: I'm not using any animations for page transitions.

Answer

Alon Gubkin picture Alon Gubkin · Mar 19, 2014

It seems like Ionic has made a lot of Android-related fixes that really improved performance. In addition, I've splitted my Android version into two versions: 4.4 and pre-4.4. Pre 4.4 is using cordova-android-chromeview which makes it so much faster. Even though it adds ~20 MB to the apk, it worths it.