Phonegap插件在首次运行时不起作用 [英] Phonegap plugins not working on first run

查看:101
本文介绍了Phonegap插件在首次运行时不起作用的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我创建了一个PhoneGap iOS应用程序,由于某些奇怪的原因,我的所有插件(Inappbrowser,SMSBuilder和amp; SocialSharing)在安装后第一次运行时都无法正常工作.只有在关闭应用程序并再次打开后,所有内容才能正常工作.

I created a PhoneGap iOS app and for some weird reason all of my plugins (Inappbrowser, SMSBuilder & SocialSharing) dont work on first run of app after installed. only after closing the app and opening again, everything works correctly.

谢谢!

推荐答案

您确实应该为PhoneGap使用单页体系结构,否则,这样做绝对是被AppStore拒绝的肯定方法.

You really should be using a Single Page Architecture for PhoneGap, not doing so is a sure way to get rejected from AppStore anyway.

如果您不希望人们坐视网页之间的加载时间,请查看Handlebars.js,这是实现此目的的简便方法+您应该查看本教程,其中涵盖了SPA/PhoneGap的基本用法. http://coenraets.org/blog/phonegap-tutorial/

You don't want people to sit through load times between webpages, check out Handlebars.js for an easy way to do this + you should check out this tutorial which covers the basic use of SPA/PhoneGap. http://coenraets.org/blog/phonegap-tutorial/

我建议反对 JQuery Mobile,因为在性能欠佳的设备上这会明显变慢,并且这也是不能使您的应用程序与简单网页区分开来的事情之一.

I would advice against JQuery Mobile as that is noticeably slower on underperforming devices, and also one of those things that does not differentiate your app from a simple webpage.

这篇关于Phonegap插件在首次运行时不起作用的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆