First steps into iPhone Development with PhoneGap, XUI JS, and Emile

Filed under: Emile, iPhone, PhoneGap, XUIJS

comments (6) Views: 9,589

So I've finally taken the plunge and started working on an honest to God iPhone application. Up until now it's just been reading about the process, dabbling with XCode, or talking to other like-minded individuals who were also in the same boat. The application I'm building will be a mobile version of Whiskerino, the bi-annual beard contest I've been a part of since 2001. It's not meant to be a replacement for the website, but more of a complement. It'll feature many of the same features, reading (and posting to) the chat window, and browsing photos, as well as being able to post your own photo. None of that is all that revolutionary. The big news is that I've decided to take the low(er) road and skip learning Objetive-C for now and use the PhoneGap framework.

What's PhoneGap? Essentially it's a framework which allows the developer to build a native, installable, available through the Apple app store, iPhone application using HTML, CSS, and JavaScript. It's even been explicitly approved by Apple. In a nutshell it allows developers to write "web" code as they normally would, but with access to a phonegap.js file which offers an API into the iPhone SDK. Once this code is written, it's compiled into an iPhone app using XCode. This means that while you can write the code using a PC, or Linux for that matter, you still must have an Intel based Mac with which to run XCode. One of the most amazing things about PhoneGap is that not only can you compile for the iPhone, but they also allow developers the SAME CODE for Android, Windows Mobile, Blackberry, and Symbian! The SAME CODE

While reading some of the posts on the PhoneGap Google Group regarding best practices, and watching Brian Leroux's presentation to Codebits in Portugal, I learned of a JavaScript framework called XUIJS developed by the same people behind PhoneGap. It's based on jQuery, and you should know how much I love jQuery. The purpose of this new framework is to be targeted towards the smaller browser landscape of the mobile market. Many of the devices are based on WebKit which reduces the amount of cross browser code required in the framework. It's stripped down, but it's also around 6k. Because of the reduced codebase, which generally means fewer features, I'm also looking into the animation library written by Thomas Fuchs called Emile.

Finally, I also submitted my enrollment for the Apple Developer Certification. I've been told that it generally takes a few days to be approved. Once I receive that approval, along with my unique developer ID, I'll be able to actually install the code on my own iPhone and test it out. Keeping my fingers crossed as this could be a huge deal.

In a sort of P.S. to this post, consider the prospect of writing JS code one time, and being able to publish it to multiple platforms (web, mobile devices via PhoneGap, and desktop software via Adobe AIR). The future is bright indeed.

Amazon logo

If this article was interesting, or helpful, or even wrong, please consider leaving a comment, or buying something from my wishlist. It's appreciated!

comments powered by Disqus