search

Home  >  Q&A  >  body text

html5 - 如何让JQM+Phonegap做的混合单页应用在原生平台运行流畅?

最近,利用JQM+phonegap做了一个hybird的小应用,但是由于大部分页面的代码都写在一个html里,导致部署到安卓后加载时间较慢。也做了一些尝试,把不同功能的页面分离到不同的html里,但是加载速度还是没有得到较好的缓解。
怎样让JQuery Mobile做的混合单页应用高效的运行呢?还是这就是JQM的弊端?

阿神阿神2835 days ago626

reply all(3)I'll reply

  • 黄舟

    黄舟2017-04-17 11:11:37

    You have to first identify where the slowdown is. If you just describe it in such a general way, it will be difficult for others to give specific optimization measures. Check out Remote Debugging, then use Timeline and/or Profile in Developer Tools to analyze where the speed bottlenecks are and consider solutions.

    I just used JQM to make a photo album at the end of last year. Because the mobile terminal didn’t have time to do it, I made it to put out the fire. Finally, it worked very well when embedded in the native application, and the speed was also ideal. Of course, I have put a lot of effort into this small module, which is considered an attempt. You first analyze what is slow, and then discuss possible solutions.

    reply
    0
  • 怪我咯

    怪我咯2017-04-17 11:11:37

    I tried Jquery Mobile last year. Because I had no experience and the optimization was not good, it was very slow. It is difficult for ordinary people to create a smooth native illusion.
    You can try asynchronous loading after separation, or reduce the elements of the main screen, and optimize DOM rendering and the like

    reply
    0
  • PHP中文网

    PHP中文网2017-04-17 11:11:37

    You don’t need JQM, it’s very slow!

    reply
    0
  • Cancelreply