0
我對混合移動應用程序有一些疑問;混合移動應用程序的API調用
1. Is the final output of a hybrid app same as native app (.app for IOS, .apk for Android) ?
2. For a hybrid app, do we need 2-way communication between web portion and native portion of the app? I understand it would depend on the app, but am just asking a general question.
3. What kind of calls are needed between native/web portion of the app? e.g. I think one would be that web portion can tell the native portion that it has loaded. Can you list down some other examples ?
4. What is the role of a library like PhoneGap in a hybrid app ?
THX爲...你說我們有專用的網絡部分和本地部分之間的雙向通信的應用程序....而且你還說PhoneGap API提供API來執行本地方法...因此對於混合應用程序,是否總是會讓Web部分(JS調用本機方法)進行本地調用,並且我們有一個回調在網絡端的帖子迴應....但我們沒有其他的方式(本地調用Web部分)? – testndtv
是的,本機代碼可以隨時在cordova webview上執行JS代碼,在iOS上你可以使用[cordovaWebView stringByEvaluatingJavaScriptFromString:「javascript here」];並在java中與cordovaWebView.loadUrl(「javascript here」); – jcesarmobile