rimon.ekjon rimon.ekjon - 2 months ago 18
Javascript Question

Backbone.JS, Angular.JS or Ext.JS - what should I learn?

I know jQuery. Now I'm feeling curious about Angular.js, Backbone.js and Ext.js. I want to know if I learn Angular.js, does it require to learn Backbone.js too. Or any suggestion about what should I learn?

Answer

Those are three very different frameworks. Based on type of applications you are going to work on I would recommend different things

  • If you are just studying and haven't really participated in any real world projects and not going in the very nearest future, take a look at polymer as it really seems to be the future of client-side development.

  • If you are working with some enterprise apps , most likely sencha / ext.js is the right way to go, because of maturity framework itself and tools around it. Sencha provides you with everything you need, however in it's own way. Tired of JS Fatigue with ever changing grunt to gulp to webpack etc? Give it a shot.

  • If you are in love with functional programming, take a look at thing like bacon.js etc, also new facebook's framework react.js has nice framework OM built on top of it, that allows you to do really neat things with immutable data structures. (However it also imply using ClojureScript)

  • If there is a need to transition application you are working on to mobile, it make sense to go with either react.js keeping in mind transition to react-native, or give meteor a shot. With react and react-native you'll end up having native application. With meteor you'll have single code base and convenient wrapper around cordova framework, that covers a lot of issues you normally deal with all by yourselves.

My personal experience is around stack of knockout.js/sammy.js/breeze.js (read and watch John Papa's materials on this approach) which we used on a couple of projects, and after a while we switched toward angular.js which we are using widely right now.

There are tons of comparisons of ember.js vs angular.js, so it is pretty easy to find all pros and cons, but again, you can easily grasp the taste of above frameworks on todomvc.com.

UPDATE: As I said in the comments, I think polymer is really technology we are going to use widely pretty soon, but it is just not here for general use in real projects. Unless you have team of JS ninjas, as docs/books/faq/SO are not here yet.

UPDATE DEC 2014: Polymer now has a lot of controls and tools around it. (check http://builtwithpolymer.org/) And since even huge enterprises are out of IE8 towards IE11 it is really a time to start using it for production. Also since Angular 2.0 is changing so much that you need to almost learn it from scratch, it make sense to skip angular and use native browser technologies to do the same, there are number of questions on SO on this topic (Replacing angular with standard web technologies)

UPDATE FEB 2015: On latest React.js conf there were talk about GraphQL and improvements to Flux architecture pattern. So right now, starting fresh React is the most viable way to go.

UPDATE MAR 2015: There is a cool framework which imho is angular done right - aurelia.js, so if for some reason you don't like the way react.js works and like angular.js better, check it out.

UPDATE SEPT 2015: Both angular2 and react are going toward using more feature rich language that is "compiled" to JS (ES5), which is right now Typescript ( with direct support for ES6/7 and JSX ). So it make sense to start playing with typescript first and then move to framework of your choose, which might be polymer or angular2 or react. Also with both angular2 and react you can make use of web components and build more future proof apps.

UPDATE SEPT 2016: ES6 is everywhere. NG2 stuff finally getting stable. React got rewritten with fibers and other stuff. Elm, Cycle.js/riot.js etc got a lot more attention. Regardless of particular framework, you are most likely will learn 3 ideas that are dominant right now in the field:

  • components as basic building blocks of UI. polymer/react/ng2/cycle.js - do that.

  • FRP - NG2 uses RX.JS, react with redux embrace FP, Cycle.js has FRP as central idea.

  • One way data/control flow - Elm cointed this approach, redux uses that approach with react/ng2/ng. Cycle.js uses this approach too.

Also Polymer hits 1.0 some time ago, and is said to be production ready. So go and watch what you can do with it: https://www.youtube.com/watch?v=-tX0e29GQa4&index=10&list=PLNYkxOF6rcICdISJclfQhj2S8QZGjXV8J

Comments