An Oracle blog about Java Technology

JSF + AngularJS = AngularFaces?

Guest Author

In case you haven't noticed, there's a pretty big shakeup going on in the world of Web UIs. Powered by several factors, JavaScript/rich client frameworks like AngularJS appear to be presenting a serious challenge to the server-side stalwarts of JSF, Spring MVC and the like. What will happen in the long run is anybody's guess.

In the meanwhile we can expect great thought experiments like the one represented by the recent survey results on the future of the view layer in Java EE applications put together by none other than java.net editor Kevin Farnham. Anyone that understands the Gartner Hype Cycle will likely observe that the crest of inflated expectations are probably already in full swing for JavaScript frameworks. In fact I would say that the reactions of the java.net readers if anything was a bit muted in favor of server-side frameworks as were some of the more well thought out comments that Kevin highlights. Another very interesting data point is the surprisingly good support for adding a new action-based/MVC web framework to Java EE in our own Java EE 8 community survey results.

One of my most recent talks titled JavaScript/HTML5 Rich Clients Using Java EE 7 actually tackles some of these very questions. Based on my years of experience working with a wide variety of clients and feedback from some JavaScript rich client early adopters I know well, it looks to me that the near future is likely one of mutual coexistence. In fact I think a very common scenario in the very near term is probably islands of JavaScript/rich client functionality in otherwise server-centric UIs. The ever vibrant JSF ecosystem is actually already busy trying to figure out this interesting puzzle. One of the most interesting such pilot projects is AngularFaces. It combines JSF and AngularJS in a way that almost makes it look too easy. If this is an approach that interests you, it is definitely a project worth checking out, not to mention the blog entry linked.

Do you have an opinion or insight on this you'd like to share? Now is a great time to express it or at least start thinking about it.

Please note that any views expressed here are my own only and certainly does not reflect the position of Oracle as a company.

Join the discussion

Comments ( 4 )
  • Oscar Thursday, April 10, 2014

    My feeling is that js frameworks are becoming more popular because of the trend about web applications with better performance. If one can put a lot of application`s logic in client side making it faster while still able to make it secure, why not do it.

    However, there is a downside. It is a lot harder to debug client side applications as you don`t have any log of browser console. You must be able to reproduce it to be able to fix it.

  • guest Sunday, April 13, 2014

    I'm very pleased to read about my little framework in the aquarium!

    A couple of weeks ago I started to explore another client side language: Dart. The advantage of this language is it's much more familiar to Java programmers, making it even simpler to combine JSF and client side programming. So I'm going to build AngularFaces 2.0 on AngularDart. That doesn't necessarily mean I'm going to drop Javascript support - that depends on the reaction of the community. What do you think?

  • Reza Rahman Monday, April 14, 2014

    It is our privilege entirely. It's a good project and we wish you well. As you know, one of the fundamental strengths of JSF is it's vibrant ecosystem.

    If it were up to me, I would personally stick with JavaScript for now. While Dart is certainly making some advances it's still very far behind JavaScript and probably will remain that way for some time: http://sogrady-media.redmonk.com/sogrady/files/2014/01/lang-rank-114-wm.png. That means as a fledgling project you will likely be more successful by relying on the predominant JavaScript skill base. I am only saying this since you asked an opinion and I wish you well, nothing more.

  • guest Tuesday, April 22, 2014

    While I am very pleased to see AngularFaces and hope that it is successful, I must point out it isquite possible to use AngularJS and parts of JSF together without any additional framework. My blog entry at https://weblogs.java.net/blog/edburns/archive/2014/02/25/just-spoonful-java-ee-makes-angularjs-localization-problem-go-away shows one aspect, internationalization, where it makes sense to combine them.


Please enter your name.Please provide a valid email address.Please enter a comment.CAPTCHA challenge response provided was incorrect. Please try again.