Frameworks Tutorials
FrameworksSeparating Logic and Presentation Layer in Ajax
Frameworks for Ajax has become the gateway for developers who are not proficient in JavaScript to develop Ajax based applications. Frameworks enable developers to build Ajax applications by using little to no JavaScript at all. There are frameworks that cater to developers who are proficient only in certain programming languages.
For example, developers who are proficient in Java could consider GWT (Google Web Toolkit) for building an Ajax based application. Developers would simply build an application through Java and GWT will “translate” the coding into JavaScript – eventually building an Ajax based application.
Since the end result is determined by the framework, there is disparity of the outcome of the application with the original coding. The client side might provide the necessary action expected by the developer however, the presentation layer could be clearly distorted.
One of the main reasons for this disparity is the inability of most frameworks to fully translate the coding. That is why modern frameworks have opted to encourage developers to learn JavaScript at least in design only. The functions will be left at the hands of the framework. This way, developers would be able to build an Ajax based application from their expected look with the right functions.
However, the presentation layer or the client side of Ajax has posed a problem for developers during integration. Frameworks should be able to work on single framework and expect their application to be rendered as Ajax. But when the application has been used up and there are certain functions that should be usable to another application.
How can the function be ported to another application? When the original function was been developed, Ajax was still be on its early stage. Because of the speed of development in Ajax, certain frameworks can be proven to be inefficient if they were never updated according to the need of the developer.
Eventually, the developer will be forced to recode the function. Instead of using the code again for another application, the developer would end up working a lot more by changing the code to fit in the framework.
What about mash-ups? Mash-ups could be regarded as the next step in developing Ajax. Because of OpenAjax, frameworks from software giants have been optimized to work with other functions. More software companies are signing up which means more frameworks with an ability to work with other frameworks will be coming in.
The challenge again comes back to the presentation layer. Since two frameworks will be working together, controlling the look of the client side will be a lot difficult because of the possibility of overlapping as well as security. There will always be loopholes in mash-ups that have always forced developers to check and double check their coding for security.
Developing an Ajax based application with a framework eases the developer’s job in building an application. However, the fast paced development of Ajax has forced some developers to work on their application again if they are required to work on a mash-up. The next stage of help for Ajax frameworks should have the ability to enable functions to be reused not only in the same frameworks but in other frameworks as well.
Sponsored Links
