Asked By: Anonymous
I’m currently on a web application project written in javascript with node.js and Express server-side and it’s time to consider the client-side of this application. The two questions are:
- Should I consider using a framework or can I write it without such a tool?
- And if not, which framework?
I’ve chosen three of these: backbone, knockout and Ember. I read all the questions I found about them but I’m still hesitating. The points to consider are:
- It is good to mix html with javascript like knockout does?
- Will my application be easily maintainable?
- Will the framework continue and not diappear tomorrow, leaving me in a very uncomfortable situation?
EDIT: And what do you think about JavaScriptMVC?
Solution
Answered By: Anonymous
As @Christian Varga has said in the comments, it depends. However, I would make the following observations:
It is good to mix html with javascript like knockout does?
With knockout you are not forced to mix javascript into the html. See Unobstrusive Event Handling.
Will my application be easily maintainable?
In my experience with knockout , if the application gets especially large the pages do get complicated. However, if you are going for a SPA style page then the code will always get fairly involved. I haven’t worked with Ember or Backbone but certainly Backbone does have a reputation for being be good for larger applications.
Will the framework continue and not diappear tomorrow, leaving me in a
very uncomfortable situation?
I think you have picked your three frameworks to consider wisely. Knockout and Backbone both have fairly wide adoption. Knockout is to be shipped with MVC4 which gives you some confidence behind its future. Ember is newer but there seems to be a lot of excitement behind it. There is a good discussion of Ember with various references to knockout and backbone here
Hope this helps you evaluate what will be best for your project.