Sunday, August 18, 2013

I saw Amir Rajan speak on various JavaScript approaches to MVC at Austin Code Camp.

I went to Austin Code Camp (put on by the Austin .NET Users Group) yesterday and saw five talks and parts of two others. I'll make blog postings for all seven. First up, this particular talk by Amir Rajan, was on a smattering of different possibilities in jsland. He experimented briefly yet significantly with many tools. All "MVC" tools were analyzed in tandem with use in ASP.NET MVC. (jQuery isn't an MVC tool in its own right for example.) His feedback:
 

  • jQuery
    • mantra: spaghetti code!
    • speed: fastest

     
  • Backbone.js
    • mantra: event-driven
    • speed: second fastest
    • go further with: Marionette (for routing)
    • If you know jQuery already, picking up Backbone should be pretty painless. This is a library more than a framework and it has a dependency on Underscore.js. One uses templates with Backbone.

     
  • Knockout
    • mantra: like Silverlight (the good parts)
    • go further with: Durandal (uses RequireJS... not django.js)
    • This tool too is more like just a library than a toolkit/solution. All JSON objects must be cast to ko.observable objects to work with them in Knockout and that is its biggest pain point. It only works in newer browsers.

     
  • AngularJS
    • speed: slowest
    • mantra: redefining what HTML is to developers
    • go further with: AngularUI
    • <input onenter="act();" id="foo" /> is an example of something you may have in AngularJS. You may define your own events such as onenter in this manner. Note we are not using the data- HTML5 convention here. Instead, Angular redefines HTML. This only works in modern browsers and has MVVM capabilities. There is a terrible performance hit in Internet Explorer 9. Use ng-repeat for looping in Angular.

     
  • Kendo UI
    • This came up by way of someone in the room asking about it. Amir had not used it and punted by bringing up a web site that had more about Kendo UI. It was a GitHub site. I did not record in my notes where he took us and what he meant to convey. (Forgive me, this was the last talk of the day and I was starting to fade.) In Googling, I can tell that there are GitHub projects of using Angular and Kendo UI in tandem.

     
  • Ember.js
    • mantra: We are moving all aspects of MVC to the frontend.
    • This is the REALLY deep end of the pool. It has the hardest learning curve and the "most bang for the buck" (Amir's words). You have to use mustache templates with Ember so you have to learn mustache.js as well in learning Ember.

     
  • Sencha Ext JS
    • has a $595 price tag!

     
  • Dojo
    • not mentioned at all!

No comments:

Post a Comment