Mobile technologies: where is North from here?

Is mobile technologies move towards HTML5, JavaScript and CSS based development?
UX Technologies article: Mobile technologies: where is North from here?

Overview

Consumer has vast choice of mobile devices available. With more and more manufacturers and software vendors like Adobe, Microsoft and Blackberry hailing HTML5 as a development platform of choice is this really a time to abandon native development and move towards HTML5, JavaScript and CSS based development?

There is no 100% answer. Like with any other software development process you need to choose your tools on project by project basis. Here's some tips on where do you want to use which technology.

First, let's have a look what do we have up our sleeve.

  • Native applications (Objective C for Apple devices, Java for Google Android devices, C++ for Blackberry and C# for Windows Phone platform)
  • HTML applications from scratch or using third party libraries
  • Others: one language frameworks which convert your code to multiple platforms (Adobe AIR, Corona labs)


Drill into more details perhaps?

Native

I heard on multiple occasions things like “XXX is too hard”, “I don't want to learn another language!” or “YYY is the language that dinosaurs used!”. But stop for a minute and think: there is a reason why vendors decided to use particular programming language. In case of Apple and Microsoft it is partially promoting their own technologies but they are mature enough both stability and support wise. In case of Google and Blackberry the language of chioce has more or less sophisticated tools and relatively large community.

So, when would you use native? Here's few points I use as beacons:

  • You applications uses standard mobile controls including long lists or standard data pages
  • You want your application to be fast and responsive
  • You application will be working with photo, audio, video


So the good example is timetable or planner application. I built planner apps using Adobe AIR, iOS and HTML and can tell that Adobe AIR came close to native but lack of features provided by native APIs helped me make my final decision.

But if my experience is no indicator to you, have a read why Facebook shifted from HTML to native iOS.

HTML

HTML5 came a long way. Thanks to development of Google, Adobe, jQuery team and many others we have a very competitive language with lots of tools, development environments and support.

So, when do you want to use HTML instead of native? Remember Facebook example above? Well, developers from Sencha (http://www.sencha.com/) decided that Facebook made wrong decision and recreated some of the Facebook's native features using HTML. Check out their blog with video examples.

So,  is HTML5 the way to go? Sure, if you are a company that have plenty of developers and experience in mobile HTML development and know how to optimise to mobile using JavaScript or ready to pay $700+ for Sencha Touch license.

Which brings us to a very interesting point: It is possible to create an app using HTML but from my experience you need the same amount of resources (if not more) to get your app look, feel and act like a native application. Majority of small teams (1 to 2 people) I've been involved with decided to use native apps next time for similar size projects .

What about cordova (phoneGap) I hear you saying? Well, it is just a native shell generator and API access via JavaScript. It works well, but if all of a sudden you need to troubleshoot, change or debug something in a shell... guess what?... you need native API knowledge. I personally like phoneGap and would like to see it prosper. It is very good tool for something custom and lightweight... I created guitar chords dictionary application using phoneGap and jQuery. It runs smoothly on iOS devices without jerking. I had less luck with timetable planner application where I was spending more time trying to find out why scrolling of lists was choking rather than implementing new features.

HTML is definitely getting there but not there yet for a team with limited resources. Both Apple, Microsoft and Blackberry saying that this is a good alternative to a native application to run on their devices, so I would consider listening to the big boys but I would also ask them to provide more examples and tutorials on how they would do it, so we actually would learn from the source rather than spending hours on google and stack overflow.

Adobe is promoting Untappd application for a few years now. It is like a social media application for beer drinkers to promote PhoneGap.
I would recommend to install it and judge for yourself how far do we need to go to get HTML experience close to native. But considering the amount of PhoneGap presentations Adobe put together this year for it's annual Max conference it is getting closer. Many are considering it is already here.

Other options

Other options can fall into two categories: free or not free.

Adobe AIR is one that resides in free category. It is basically Adobe Flash runtime packaged with virtual machine which runs on Apple, Android and Blackberry devices. Adobe decided to concentrate on promoting it mostly for mobile game developers but I had a lot of fun building timetable app using Adobe AIR and Flex (mobile components for Flash, i.e. table view). I haven't touch it for about a year now since Adobe donated Flex to Apache foundation but I would really like to use it if working on game like app or something very custom looking.

I haven't worked much with paid options, but they all share very similar concept: writing application using Lua or C (Corona Labs), C# (Xamarin, former Mono Touch) which transcodes the code into native code using Software Development Kit. When I was doing “Testing Mobile Applications” workshop with Jonathan Kohl he compared the process to “translating from French to English via Italian”. He sure has a point but the option is there for everyone to try.

Conclusion

Being technology agnostic but concentrating on right tools and rapid development for the task is hard. Judging by above examples there is no silver bullet when it comes to mobile development. There are a lot of unanswered questions:

  • HTML or Native?
  • Would paid frameworks lock me in or provide better support and rapid development?
  • Should I go with third party free tools or am I risking them being abandoned as they aren't locked in to particular hardware?


And the only way to answer those is to build application using each framework of interest. Whatever you chice is, remember: even basic knowledge of native frameworks and specifics of each platform is very important!

P.S. One last example:  Metronome app. Building Metronome both in JavaScript and Adobe AIR required extra class to correct and adjust time after each cycle. Both ActionScript and JavaScript can easily go out of sync shifting 1 to 10 ms in time each second. You don't usually need to do it native applications.

The Author

Vladimir Roudakov

Solution Architect / Social Engagement