I am building a Phonegap App with jQuery Mobile, and the entire App is dynamic, it's loading data from an API. I have about 10 pages and the App is running too much slow on the Phonegap, but when it comes to native browser it's fast. There's something that I can do to speed up the Phonegap or wherever?
相关问题
- Views base64 encoded blob in HTML with PHP
- Is there a limit to how many levels you can nest i
- How to toggle on Order in ReactJS
- void before promise syntax
- Keeping track of variable instances
The another way apart from disabling the CSS is that to remove or work with alternatives for GC.
JavaScript is GC based language. It means, it has unpredictable GC time which makes main thread stops. This makes UI struggles. On native implementation, you have control to use GC or not.
This wouldn't be a problem on Android. Android always had those struggling because of GC on Java. Considering this fact, most of Android users doesn't care about UX a lot. But on iOS, your HTML5 based app never be better experience than competitor's native app.
There are many workarounds for this GC time issue. Such as incremental-GC, realtime-GC and so on. But actually, there's no real solution. Because the primitive problem is you don't have control.
Try disabling some of the CSS that slows it down. In your jquery mobile .css file add this to the bottom: