Friday, February 21, 2014

Web technology: JSF vs angularjs

I use angularjs in one of my recent project. I had been using JSF since the very beginning, almost 10 years. My conclusion is that angularjs is definitely the way to go.

Learn curve.

Assume that you know javascript/html/dom/jquery concept, the basic set of tool for web development, angularjs definitely wins out. I spent two days over angularjs documentation and starting coding after it. I believe I am an expert after one month. Have question on it? No problem. Test it out in offline html, plunker, or dig into the angular.js source code.

On the other hand, JSF is not so easy. Check out here how many chapters you need to go through before you can start work on it.  There are tons of concepts and API.  Suppose you are good at learning new stuff and ready to go right now, you will be surprised! The build/render concept is subtle and very difficult for beginner. Even experienced developers are bitten by it from time to time. Do a search on JSF build/render. You can find out how many questions are asked.

Reusable UI component

JSF struggles hard to provide facility to author reusable component. First authoring a new UI component is not easy, even right now in jsf 2.2. JSF 2.0 provides composite component and resources. It seems framework is there. Component developers are ready to go.  Developing component to show some text is easy and it always work. Once you are trying to develop some component with form fields, trouble will comes. It works in your test, but not in some situation. From my experience, this is related to component state management by UIData(html datatable or UI repeat). JSF just can not handle the input state component if they are deeply nested in UIData. Go mojarra issues track to search for UIData related issues. You are surprised how many are unresolved, or reopened.
Even the component is for static text display, it is not easy to use. Here is one comparison example. To display a tree in html, I use popular primefaces library. You can find out how many class you need to write at server side to just display the tree.   I did a search before writing up this post for tree component in angularjs. Here is an example.  You just need to supply a tree-style json object, just as I expect, as simple as it.


JSF library is buggy, just because its concept is complicated. In lasy two years, I reported around ten bugs in mojarra. I did not find any bug in angularjs core library so far.


Angularjs is simple. It core library is only about 20,000 lines. Most of it is inline documentation. It can be easily understood. On the other hand, JSF is way too complicated.If you do not believe, grab the mojarra source code and try to figure out how it does its trick. Why do you need to read the source? Soon or late, you find your code does not work. You need to understand why it does not. The source comes to rescue at this time. So you need to understand portion of source related to your problem.

Server requirement

JSF: CDI for scope management. EL for data binding. Bean validation for validation.
Angular js: JAX-RS for data. No scope is need. Data-binding is done at client side. Validation can be done easily in client side.


JSF: many options.
 angularjs: do we have such thing like configuration?

Case Study


  1. Well done. Excellent article, thanks for confirming.

    1. IEEE Final Year projects Project Center in Chennai are consistently sought after. Final Year Students Projects take a shot at them to improve their aptitudes. Final Year Project Domains for IT

      JavaScript Training in Chennai

      JavaScript Training in Chennai

      The Angular Training covers a wide range of topics including Components, project projects for cse. Angular Training

  2. It's pretty good article and i am getting some useful points here thanks for sharing from
    Angular training in chennai

  3. This is very useful post to understand web technology JSF vs angularjs. I learn many factors related this technology from here. USA web application developer

  4. Angular.JS is used to develop the single page web application. The ideal architecture is Angular.JS with JAX-RS. But we can have JSF server side reusable component also.

    Angularjs Training | Angularjs Training in Chennai

  5. PHP provides the best option to build the website where we can design our website in a very interactive manner that provides better functioning in data management.
    PHP Training in Chennai | PHP course in Chennai

  6. You provide one of the best blog that you share.This is very useful to all the user to improve their knowledge.Thanks for sharing.keep shaing more blogs.

    Angularjs Online Training

  7. Good post and I like it very much. By the way, anybody try this app development company for iOS and Android? I find it is so professional to help me boost app ranking and increase app downloads.


  8. The great service in this blog and the nice technology is visible in this blog. I am really very happy for the nice approach is visible in this blog and thank you very much for using the nice technology in this blog
    Angularjs course in chennai

  9. The blog you presented was very nice and interesting which helped me to get update on the recent technologies.

    angularjs training in chennai

    devops training in chennai

  10. Thanks for one marvelous posting! I enjoyed reading it; you are a great author. I will make sure to bookmark your blog and may come back someday. I want to encourage that you continue your great posts, have a nice weekend!
    Online training in USA

  11. Marvelous and fascinating article. Incredible things you've generally imparted to us. Much obliged. Simply keep making this kind out of the post.
    AngularJS Training in Chennai

  12. Good job! Fruitful article. I like this very much. It is very useful for my research. It shows your interest in this topic very well. I hope you will post some more information about the software. Please keep sharing!!
    German Classes in Chennai
    German Language Classes in Chennai
    Hadoop Training in Chennai
    Python Training in Chennai
    German classes in OMR
    German classes in Porur
    German classes in Tnagar

  13. This is a very amazing post for cheap web hosting services. in this post, you have provided all the basic information regarding.

    website builder for reseller

  14. Comfortabl y, the post is really the freshest on that deserving topic. I harmonise with your conclusions and definitely will thirstily look forward to your next updates.

    private label website builder

  15. Thank you for the link building list.I am going jot down this because it will help me a lot.Great blog! Please keep on posting such blog.

    white label website builder

  16. thanks for your concept it's very amazing information keep update the details thanks for itweb design company in velachery

  17. Thanks for Sharing This Article.It is very so much valuable content. I hope these Commenting lists will help to my website
    top angularjs online training

  18. We read your blog , share most useful information in blog .
    Custom Mobile App Development