简体   繁体   中英

Developing in Android Studio versus Framework (e.g PhoneGap)

I wanted to get a more experienced opinion on something I recently found out. A couple of months ago I set a goal to build myself a mobile app, and the first thing I did was go to developer.android.com and begin reading documentation on how to go about doing this.

I've invested a lot of time in understanding Android Studio and how to make simple apps (and I'm just now getting the hang of it all), but I just recently read about frameworks like PhoneGap(which let web devs who know HTML,CSS, and Javascript make apps too).

Before learning Android, I taught myself web dev through the Odin Project, which taught me a fair amount of HTML, CSS, and Javascript (little iffy on this language, but I'm sure it's something I could pick up easily since I already have a bit of experience).

I'm wondering what you guys feel are the limitations of using these frameworks and whether I should switch over to them, as opposed to continuing with Android since things are beginning to click for me.

Thanks!

I have developed apps for both Android and Phonegap. Phonegap takes advantage of your web development experience and lets you build mobile apps with ease. But it's not a replacement for Android API itself. A good phonegap application requires knowledge about web development and Android API.

However if your aim is to develop an android application, and you are comfortable with web development and Android, I would advice to take Android API.

Phonegap as wonderful as it is for web developers, and startups who can't afford to have dedicated resources for Android, iOS separately, has its limitations.

  • Performance : Phonegap app's performance is not at par with a native android application.
  • Functionality : As one would expect you can't have all the functionality support a native android application has.
  • Look : You could easily tell apart a phonegap application from a native one. Given phonegap renders all the content in a webview, the look of native ui elements is lost

I think you will always need access to the native API to make good apps. At least the navigation should be native, so that your app has the look and feel that the user expects, and so that stuff like the back button get correctly handled for you.

Even if there is some plugin that does that for you in a perfect way, I believe it's beneficial to know how Android works. In the end, frameworks like PhoneGap add a layer inside your app rather than removing one, and it's always better to understand what goes on inside your app.

So the time that you've spent learning native Android won't be lost. However, it makes sense to use HTML/JS if you want to share code between different platforms. I think this article from Basecamp shows a very compelling example: https://signalvnoise.com/posts/3743-hybrid-sweet-spot-native-navigation-web-content .

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM