Apache Cordova (aka Phonegap).
A little clarification on the name. The NEW name will be Apache Cordova. After Adobe bought the development firm that was working on Phonegap the Phonegap project itself was given to Apache Software Foundation to maintain its open source roots and continue development. As of this writing the transition is still underway with MOST, but not all, elements haven taken on the Apache Cordova persona.
Our First App On Cordova
Our first app that we wrote using Cordova was the Abundascan application for Abundatrade. The first release is a simple app that uses the camera to scan a barcode then sends the UPC to the Abundatrade server to get real-time prices that they will pay for used books, CDs, DVDs, and video games. Functionally the app is simple and works well. However one key element here is the primary reason we started with Cordova over other cross-platform tools like Corona, the camera.
Turns out that many of the cross-platform tools do NOT support the camera interface. That shot down Corona right away, which otherwise looked promising.
Cordova And Cameras
Luckily there is a good camera scanner app that reads UPC,and other machine-enabled codes like QR, codes created by Google released in the ZXing project. The ZXing applet is ported and ready to use for Cordova as a plugin.
Cordova Camera Caveats
The bottom line, we have yet to get the camera plugin to work on IOS4 or higher devices. In theory the demo app works, but we’ve yet to see it on our iPod Touch or newer iPhones.
The Android Version of Abundascan is out, but we still are having issues with Cordova on IOS.
Our Second App
Our second app is a little less ambitious as it is testing the waters for a larger project. This app is simply a screen that shows your current GPS location with exact latitude and longitude. Where Am I Standing? is a free app that does just that. To make it a little more interesting we wanted to add an info page with our name and logo and a little bit of graphic “window dressing”.
Again, here we ran into multiple issues. This time noticeable right on the Android before we even attempted the iPhone release. We want a simple app with no glitches yet there are several things that still aren’t right. We can spend a good bit more time addressing in convoluted code to workaround quirky UI elements. Others are as-yet un-fixable.
Technically it was easy & works well. Aesthetically it is NOT of the caliber I want it to be at. As I dug deeper into this I uncovered a lot of hidden secrets about mobile app development and why 99.99% of these cross-platform tooks like Cordova fail.
Here are the “little details” that are compromises I don’t want to make. I want to build QUALITY apps. That means making them as perfect as we can, and this stuff is far from it:
– Swipe Right / Left : I wanted to be able to simply swipe the main screen to see the info screen (“created by Cyber Sprocket”). One swipe works, then it breaks. This is a fundamental issue in the browser kit Cordova uses as the foundation for their solution. Google developers refuse to address it saying it is “as designed”.
– Vertical Page Scrolling : I don’t want ANY page scrolling, jitter, etc. The pages are too “tall” and are scrollable if you swipe up or down. This can be fixed but takes extra coding to do so. What a pain.
– Button Highlighting : Sometimes the highlights on the info/home buttons “stick”. This is a built-in feature of jQuery Mobile and Cordova. It is wonky at best.
– Screen Hesitation: Even on a mid-range phone with just about the simplest app possible, sometimes going to the “info” page hesitates, same with going back to home.
– Navigation History : Go to info, then back to home. Each time you do this is adds to the “history”. Do it a few times and your back button is loaded up with a bazillion loops of home/info/home. Again, fixable with code (mostly) but why?
While Apache Cordova may be a great tools for building a functional prototype or possibly building corporate apps where users may value function over form, in my opinion Cordova is a compromise.
I’m sure we can build quality apps with Apache Cordova, but this is not about CAN we do that, it is about what are the benefits of doing so. From a business perspective there appears to be little gained here over a process that includes solid architecture, documentation, code design, and good old-fashioned cross-platform awareness and porting.