RIA: HTML5 & Flex – An Overview

The current trend in computing is to move away from dedicated desktop-based applications and towards applications that are delivered from, and run in the cloud. Developers are striving to replicate the functionality and experience of desktop applications in order to create Rich Internet Applications (RIAs) which combine the convenience, flexibility and portability of web services with the rich user experience of the applications users are used to on the desktop. What actually counts as an RIA is open to discussion: some prefer to reserve the term for applications that are developed through a plugin system or framework like Adobe Flash, Adobe Air or Microsoft’s Silverlight, while other are happy to include software based in HTML and JavaScript technologies like AJAX. Here we’ll compare two technologies that can be used to develop rich internet applications: Apache Flex and HTML5.

Apache Flex, formerly known as Adobe Flex, is an SDK for developing Flash-based applications. First developed by Macromedia, which were subsequently acquired by Adobe, and then open sourced under the aegis of the Apache Foundation, Flex is a mature and advanced framework that offers pre-defined components for building applications. It is used in numerous high-profile applications around the web, including mint.com and the BBC iPlayer’s desktop component. The Flash plugin is almost universally available, with many hundreds of millions of deployments around the web. However, along with the ending of active development of the mobile version of Flash, the open-sourcing of Flex was seen as an acknowledgement from Adobe that HTML5 is the future of rich internet application development. Flex had already been largely open-sourced – there are standardization and development advantages to open source – but the transfer of the management of Flex to the Apache Foundation indicates a refocusing on technologies other than Flash.

Until recently Flash-based frameworks have been just about the only game in town when it came to developing RIAs, but it is not without its drawbacks, a major one being that it is not always wise to base software on a single vendor solution with little competition (Silverlight is nowhere near as prevalent). Flash has tended to be slow and buggy, particularly with regard to security exploits and it has made some enemies, especially within the mobile space. Apple will not distribute Flash with its iOS devices, including the iPhone and iPad, and, as mentioned, Adobe have recently announced that they will no longer be developing Flash for mobile. If a developer wants to target mobile with their application, and let’s face it, who doesn’t these days, Flash will soon not be an option.

Which brings us to HTML5. HTML5 is the next iteration of the hypertext markup language, and it includes a number of features that are designed to appeal to RIA developers. It adds video and audio tags, a canvas tag for animations, and client-side offline storage. Coupled with JavaScript, which has undergone enormous improvements in speed in recent years, for client-side scripting, RIAs can be created to run within browsers without plugins. The advantages of using open standards are clear; there is no vendor or platform lock-in and HTML5 does not have many of the disadvantages of Flash. However, HTML5 is a nascent technology, still in active development, and subject to change. Browser support can be patchy, especially in Internet Explorer. It is, however, the way to go for mobile rich internet applications. Even though HTML5 is still some way from being complete, creative web developers have been expoiting the improvements it brings to make exciting rich internet applications. Some notable examples are the social media dashboard Hootsuite (http://www.hootsuite.com) and the drawing application MugTug Sketchpad (http://mugtug.com/sketchpad/).

HTML5 is the technology of the future, and even Adobe have recognized it, throwing their  weight behind HTML5 and abandoning Flash on the mobile platform. Flex and Flash are certainly still viable technologies for RIAs, and there are areas where Flash is preferable, especially those where applications require DRM, but HTML5, in time, will become the reigning technology.