Tag Archives: Flex Vs JavaScript

UI for RIA

RIA stands for Rich Internet Applications. RIAs have features and functionalities which are seen in the conventional desktop applications. While maintaining the advantages of web applications, RIAs make use of rich graphics and streaming media scenes.  The designing part of RIAs is very important that makes use of web infrastructure combined with client-side application to carry out the presentation.

A typical RIA is comprised of three layers; the presentation layer, business layer, and data layer. The presentation layer is the layer that contains UI and the presentation logic components.

RIAs can be simple or complex and their design and implementation varies accordingly. However, in the presentation layer, which contains UI, it is important to have good architectural design. Interfaces can be simple to overlay the back end the businesses services or can be complex that can perform most processes themselves and communicate back end information.

Let us talk about some general design considerations followed while designing for UI. These considerations will help you when designing RIA according to your requirements and perform efficiently when expected.

When designing a RIA, consider the audience. Consider designing RIA only when your vital audience makes use of browser that supports RIAs.

Consider the complexity of your UI requirements since RIA implementations work best only when they use single screen for all operations. They find it difficult to work with multipage UI. Though they can be extended to multiple screens, it requires extra code and screen flow consideration. With such screens, users should be able to navigate easily or can pause and return to a particular point easily and quickly, instead of starting the whole process over and again.

If there are multi-page UIs, you should use deep linking methods. In addition, you need to use carefully the Uniform Resource Locator (URL), the history list and the browser’s back and forward.

Since RIAs are meant for providing rich user experience in whatever way they can, there should be more sophistication and more user interactivity.

With the help of RIA, client and server computers can communicate without any irrelevant page refresh. Web applications can support different user interactivity with just single screen. Users can interact in real time as information can be seen on same page on which it was requested.

Improved user interface on RIAs not only increased convenience in the user interactivity but also made it more interesting. UI designers make use of animation, sounds and graphics for improving the user interface. There is large range of options available for the visual interface design. Designers can use more graphic elements as these graphic elements available in RIAs use less network bandwidth.

Using Rich Internet applications, designers and developers can now offer Web site users better User Interface and more functionality that is needed for application interfaces. It helps them create web applications that are more user-friendly. It also helps in increasing ROI. Users become more productive and hence dropout rates go down that result in increased number of completed transaction.

Flex vs JavaScript why flex is better

Flex Vs JavaScript; this is a debate brewing up for long. Though both the languages have their own pros and cons and each of them has its fan following, you can’t do away with the bias that pops up in any discussion related to them.

Flex and JavaScript are both the different ways to develop the Rich Interactive Applications or RIA. Though JavaScript and Flex Actionscript are based on ECMAScript, there are some differences which make one better than other is.  The latest version of JavaScript is dynamically typed language while ActionScript is statically typed one. However, both of these are made for application development.

What is Flex

Flex is a programming language developed by Adobe Technology. Meant for developers, this language offers more tools to develop rich internet applications.  Equipped with all the Flash features, this language is comprised of two languages MXML and Action Script respectively.  For developing Rich Internet applications, Adobe Flex makes used of Sun’s Java environment.  For Flex coding, MXML is used that is based on XML.  All the Flex codes are complied into SWF (ShockWave Flash) files, like Flash. These SWF files can be directly executed in browsers having Adobe Flash Player Plug-in installed.

What is JavaScript?

JavaScript is also a programming language used to make web pages interactive. Most browser support JavaScript and visitors to your website can run your JavaScript if they have browsers supporting JavaScript. JavaScript is an OOP based programming language having built-in objects and functions. It allows users to build their own objects and functions.

Flex Vs JavaScript

So which one is better; Flex or JavaScript?  We are talking from the point of view of developers. For them language is better if it provides required framework and UI toolkits. While developing a RIA, developers do not want to do everything from scratch otherwise; it will lead to lots of additional work.

Let us talk about JavaScript first. It does have libraries like jQuery that helps you manipulate the broken document object model for all browsers. Supporting JQuery, there are several other plug-in also. In addition, there are JQuery Mobile and jQuery UI, though they are at initial stages only. Then there are ExtJA, Sench Touch for mobile development.  There are a few application frameworks for JavaScript including Sproutcore, Knockout, Backbone.js and others. However, the choice of framework depends upon the kind of application you are developing.

When it comes to Flex, most developers agree, despite all its features, toolkits, JS library or framework, JavaScript  is nowhere close to Flex/AS3 features. Flex has been there for years and its componenets developed   have been considered mature. It offers variety of components to deal with different cases. It offers great styling and skinning options, good documentation, many examples, layout management and data binding.  Moreover, if offers many non-visual components and classes to help you build data-driven applications. Flex is definitely better than JavaScript.

Let us compare both web technologies with the help of a comparison table

Flex JavaScript
Flex framework helps in creating rich user interfaces, as it is component-oriented and event-driven. JavaScript is a programming language.
It is used mainly to build a stateful application that runs on client-side only. JavaScript is good for cross-browser portability
To run SWF files created by flex, clients must have flex framework installed. No such restriction exists for JavaScript
Debugging is very easy with flex as it has an inbuilt debugger and profiler within the Flex builder IDE. For JavaScript, debugger might not be useful as it involves many browsers.

Action Script in Flex is easy to learn as it includes components of java and JavaScript and has strong OOPs support.

JavaScript has different syntax and execution for different browsers.