Gettin' mobile-webby wit it (Native vs PhoneGap vs Titanium)
Fri, Jun 21, 2013Yes, that was a Gettin’ Jiggy Wit It reference.
Lately I’ve wandered from iOS land into the world of non-native app development, and I’m going to be in hot pursuit of performance boosting CSS techniques, handy-dandy HTML5 tricks, and browser-compatibility smoothing for the next few weeks. This post: two tiny but packed articles and then a PhoneGap Vs Titanium Vs Native comparison. TL;DR: I’m prototyping with PhoneGap because it has the smallest learning curve, the widest reach, and because the mobile web is improving rapidly these days.
I found two great (and very concise) articles on HTML5 from Adnane Belmadiaf last week, one with 5 need-to-know HTML5 features, one with 5 awesome HTML5 + Javascript mobile APIs. The APIs are pretty mobile-awesome, check them out.
I mentioned a few days ago that I found a great PhoneGap + AngularJS tutorial. This was after I spent a few days making the classic PhoneGap Vs Appcelerator Titanium decision. I have always been a huge Native-is-just-always-better advocate, without having done much research into any hybrid or otherwise non-native tech. However, the draw to build once and deploy everywhere is a strong business and dev-speed motivator, and a little research has pushed me into the prototyping stage. Below is my take per platform so far, according to experience plus some readings from StackOverflow, a quick post from a guy who went native over non-native, and a BIG post from a Titanium employee who breaks it all down in a very fair and very informative way.
PhoneGap gives web developers a chance to build an app for every device with a browser one time, using html, css, and javascript (assuming you don’t need any true native functionality). It runs a ‘native’ app that fires up the device’s native browser to run a web app, and connects to device features via the PhoneGap API.
Advantages:
- Developers can build and test the app in their own browser
- You don’t need specialized devs for each language/device (at least not for the entire app)
- Devs can write their own plugins to hybridize (mixing with true native parts of the app)
- The app can be hosted elsewhere online, giving you magical update-everywhere-anytime powers
- PhoneGap can hit, what, 7 different OSs? Apple, Android, Windows, Blackberry, etc.
- Web apps might not “feel” native, leading to a potentially poorer user experience (although this is getting better as mobile browsers improve and developers get smarter about performance)
- Browser-compatibility becomes an issue (although you’d have fragmentation headaches going native anyway)
- Devs have to learn to work with PhoneGap (there’s always a learning curve)
Advantages:
- A closer-to-native feel that can be written in Javascript (you are basically working with JS-ized native elements)
- Devs can build their own native “modules” to interact with (similar, I think, to PhoneGap’s plug-ins)
- Potentially faster-than-native development speed (build once, deploy to iOS and Android)
- Higher learning curve (new IDE, more in-depth API, and no html/css control - you are essentially building a native app with Javascript)
- Only supports iOS and Android at the moment
- Devs can’t test in the browser the way they could with a web app (although PhoneGap apps should really be tested on the device/in simulators anyway)
Fully native apps, however, are not always accessible to the whole development team (unless you are REALLY stacked), and keeping content, style, and updates consistent can become a project management nightmare.
My thinking at the moment: if PhoneGap has the fastest development speed and modern browsers are rapidly improving, why not take that chance? If the UX is comparable and we can avoid the unholy Apple App Store update process with some dynamic content, then I’m sold. And if there’s anything that the mobile web can’t handle, we’ll just link to a native view for that piece of complexity.
I’m prototyping now. The new fear: if my app sucks, is that my fault or PhoneGap’s?