Life After Flash: Alternatives for In-Browser Rich-UI Applications

1539 views

Many of us were in such situation. Imagine: you gamble online and are caught up in wonderful sense. Excitement rushes through you as the game goes on. The thrill is high and so are the bets. Only one second is left till the end of the game and you are winning, but… “Adobe Flash plugin has stopped. Send crash report”…

10Flash and Adobe’s related products were considered the “Kings of Feature-Rich UI” for many years. Initially Flash had great success as a tool for developing applications with complex front-end and animations, and many programs are still using it. Moreover, brand new content is still often created using Flash. But gradually, its use has been decreasing over the last 5-7 years, in part due to the lack of support on smartphones and partly because it’s vulnerable to attacks (which can lead to personal information leak). Its vulnerabilities are often criticized by large companies (e.g. Steve Jobs’s “Thoughts on Flash” are just classics). Browsers often limit their support of Flash, and Mozilla, for example, blocked Flash by default since July 2015.

In July 2015, Facebook’s security chief Alex Stamos publicly called for Adobe to kill off Flash. “It is time for Adobe to announce the end-of-life date for Flash and to ask the browsers to set killbits on the same day,” he said in his tweet.

And…

Recently Adobe officially advertised HTML5 as a “web platform of the future across all devices” and encouraged developers “to build with new web standards”. Adobe’s new tool of creating rich animations, Adobe Animate CC, is intended primarily for working with HTML5.

Rewriting an application from Flash into other technologies is now just a matter of time, rather short time. Let’s look at the most plausible alternatives for cross-platform in-browser apps, keeping in mind the key expectations of potential users with respect to such an application.

 

           

In-browser app should load and run quickly, work in mobile browsers, always remain stable and predictable, and of course, use modern technologies which will be supported in the next couple of years.

 

   

Challenger 1. HTML5

HTML5 is an umbrella term, a concept, rather than a single technology. It refers to HTML, CSS and JavaScript. These three technologies, when used together, can produce truly amazing results. HTML is aimed principally at maintaining simple and understandable code, and CSS and JS allow building more complex software. JavaScript is a full-fledged client-side scripting language with many unique features. Its main advantage is making apps more dependent on the client side.

HTML5 is a brilliant assistant for developing dynamic websites and applications. Even giants like YouTube are switching to this set of technologies. Also, it is used and supported by a lot of people, so there is a huge community around it. This promises HTML5 a long life and continuous evolvement.

Life After Flash

As for general-purpose applications, developed on HTML5, there are several most common JS frameworks used to build complex front-end. Most of them are currently developed by large and well-known companies. For example, Angular.js is sponsored by Google, React.js – by Instagram and Facebook. Backbone.js has been very popular historically because of the lightweight structure and ease of use compared to other frameworks (according to developers’ feedback), and even such huge products as Foursquare and Airbnb are built on it.

HTML5 games are growing and developing as well as tools for creating them. For example, Phaser.js, suitable for the production of mid-size games. It is free open-source framework for developing desktop and mobile games. Phaser.js focuses on game logic and implements a huge range of pre-built classes, which allows you to make games very fast. Currently the technology has several corporate contributors.

The second great framework is Create.js. It is sufficiently unified for browsers and officially sponsored by Adobe, AOL, Microsoft and Mozilla. This means, the framework will be kept up-to-date and Create.js-based apps will be relatively stable and predictable.

It is quite easy to start working with HTML5, since JS, HTML/CSS are included into the basic university program for IT-related specialties. Some even learn them on their own out of curiosity. On the other hand, creation of a rich-UI app, especially a game, requires really high professionalism. And according to the feedbacks of our developers, HTML5 in games has serious productivity issues. Due to these shortcomings, there might be limitations with respect to the size and number of animations on the screen. Moreover, if you look to create a 3D game, you will have to rely on WebGL, which doesn’t work in some mobile browsers. So not every functionality and graphics can be implemented with HTML5, but the technology is improving right now, and we hope that in the future it will become a brilliant tool for making high-complexity games.

QA is another factor to consider with respect to HTML5 application development. HTML5 tools are supported by browsers in different ways. So although the technology is cross-platform, during HTML5 mobile application development you’ll have to test your app on each device and in each browser separately.

 

HTML5 is a cross-platform kit of well-established and globally known technologies with a lot of individual and corporate contributors. Also, many programmers are interested in working with it, as such projects are good for portfolio. On the other hand, HTML5 application development requires really high professionalism, and its capabilities are limited when you need to create a more complex interface or a 3D game. Also, you will have to keep an eye on every step of testing and bug-fixing, especially if you are targeting a lot of mobile devices.

   

   

Challenger 2. OpenFL

OpenFL is an open-source framework and platform. It is written in Haxe programming language and allows developers to create different multi-platform applications. OpenFL is designed to fully mirror the Flash API. The technology is new, the initial release was in 2013. By now it has not too many contributors as compared to the languages and frameworks described in the previous section, but the community is active, so we can call OpenFL a “sufficiently supported” technology.

Life After Flash

Basically, you write your code in Haxe, then you link against the OpenFL library to get the functionality of the Flash API.  You can keep using a lot of the same tools in parallel, FlashDevelop IDE has excellent support for Haxe. The same Haxe code compiles to Flash, HTML5 and even C++.

So if you are a Flash developer (and are ready to learn Haxe), you are likely to get used to OpenFL quickly, as the APIs are identical. Also, if you already have products written in Flash, you will be able to port them into Haxe using OpenFL.

On the other hand, although Haxe is considered an easy learning curve, you have to keep in mind that it is still a new language and is outside the TOP-50 most popular programming languages.

Also, you have to be prepared for some little gaps when using OpenFL. There is feature parity for pretty much everything except few less-common functions maybe. On the other hand, it has asset libraries that Flash pipeline doesn’t have. Indirect bug-fixing is another concern: you fix the code in Haxe, then it is compiled into HTML5, which is “understood” by browsers. So it is hard to predict how much time you’ll need to fully build the relationship between different code fragments in each situation. Anyway, you are likely to be “lost in translation”.

 

 

OpenFL can become a useful assistant to Flash developers looking at alternative technologies and trying this and that. Also, is can help with porting a Flash product into Haxe. But you have to be prepared for difficulties with cross-browser bug-fixing and lack of documentation, as the technology is new.

   

Challenger 3. Jangaroo

Jangaroo is a product of the CoreMedia Company. It contains a compiler that translates ActionScript 3 code into JavaScript, so it is introduced as “AS without Flash”. This tool only needs the last version of Java Runtime Environment and Maven.

Life After Flash

Interestingly, the name of the tool is not a coincidence. According to the official page, “The ‘J’ hints at JavaScript whereas the ‘oo’ stands for object-orientation. The allusion to ‘kangaroo’ is not coincidental, either: you should be able to make much bigger jumps with Jangaroo than with JavaScript 1.x alone” J

Jangaroo is bravely advertised as a tool for those who wish to do “programming in the large”, e.g. for Flash developers who wish to continue OOP instead of fully moving to HTML5, and at the same time – to use the benefits of JS. And also, you’ll no longer be dependent on Flash plugins.

But it needs to be noted that the tool at the present moment has a tiny community, which pleases us with new updates not really often. So you are likely to face the lack of vital documentation. Also, like with OpenFL, when working with Jangaroo, you have to be ready for “indirect” QA and bug-fixing.

 

 

Jangaroo can be a solution for Flash developers who wish to keep using this language and enjoying the advantages of OOP, while also utilizing the benefits of JS. The weak points of this technology are the necessity of testing bugs in JS through a different language. Also, a potential problem is the missing documentation and unstable support.

   

‘To Flash or not to Flash?’

It is not the question. The question is – which alternative is better. As you can see, the most common and universal tool is HTML5 – it is comprehensive enough to cover the needs and problems that arise when you are creating an application for web and mobile platforms. However, according to our experience, catching all bugs and sorting them out might take a lot of time. Each app should be tested, especially on mobile devices – each OS, each version of the device literally has its unique set of bugs J

The tools like OpenFL and Jangaroo are interesting and seem promising, especially to the developers who are already using Flash and are principally unwilling to move to HTML5 or just do not have much time for learning all its intricacies. These tools are cross-platform, require no extra plugins and allow quick compilation of the existing code from Flash into another language. However, it is important to remember that these technologies are less documented and thus less predictable in use.

Still, there are too many options to choose from, and all of them have their advantages and weaknesses, and it is hard to make the right choice. Over the 10 years of our work in the market, Unicsoft has dealt a lot with Flash and HTML5 application development and other cross-platform technologies. Based on our experience, we suggest that the right technology for feature-rich front-end can be selected only after a careful analysis conducted by a professional tech lead. And we will be happy to provide such a consultation, it is a free-of-charge service for those who seriously consider a transition from Flash or are stuck at a certain stage of their cross-platform application development. For more information – check or expertise in game development and JavaScript development.

 

Thanks for reading!
Related posts