ember.js – the right choice for the Open Event Front-end
With the development of the API server for the Open Event project we needed to decide which framework to choose for the new Open Event front-end. With the plethora of javascript frameworks available, it got really difficult to decide, which one is actually the right choice. Every month a new framework arrives, and the existing ones keep actively updating themselves often. We decided to go with Ember.js. This article covers the emberJS framework and highlights its advantages over others and demonstrates its usefulness. EmberJS is an open-source JavaScript application front end framework for creating web applications, and uses Model-View-Controller (MVC) approach. The framework provides universal data binding. It’s focus lies on scalability. Why is Ember JS great? Convention over configuration - It does all the heavy lifting. Ember JS mandates best practices, enforces naming conventions and generates the boilerplate code for the various components and routes itself. This has advantages other than uniformity. It is easier for other developers to join the project and start working right away, instead of spending hours on existing codebase to understand it, as the core structure of all ember apps is similar. To get an ember app started with the basic route, user doesn’t has to do much, ember does all the heavy lifting. ember new my-app ember server After installing this is all it takes to create your app. Ember CLI Similar to Ruby on Rails, ember has a powerful CLI. It can be used to generate boiler plate codes for components, routes, tests and much more. Testing is possible via the CLI as well. ember generate component my-component ember generate route my-route ember test These are some of the examples which show how easy it is to manage the code via the ember CLI. Tests.Tests.Tests. Ember JS makes it incredibly easy to use test-first approach. Integration tests, acceptance tests, and unit tests are in built into the framework. And can be generated from the CLI itself, the documentation on them is well written and it’s really easy to customise them. ember generate acceptance-test my-test This is all it takes to set up the entire boiler plate for the test, which you can customise Excellent documentation and guides Ember JS has one of the best possible documentations available for a framework. The guides are a breeze to follow. It is highly recommended that, if starting out on ember, make the demo app from the official ember Guides. That should be enough to get familiar with ember. Ember Guides is all you need to get started. Ember Data It sports one of the best implemented API data fetching capabilities. Fetching and using data in your app is a breeze. Ember comes with an inbuilt data management library Ember Data. To generate a data model via ember CLI , all you have to do is ember generate model my-model Where is it being used? Ember has a huge community and is being used all around. This article focuses on it’s salient features via the example of…
