Ember.js is an open-source client-side JavaScript web application framework based on the model-view-controller (MVC) software architectural pattern. It allows developers to create scalable single-page applications by incorporating common idioms and best practices into a framework that provides a rich object model, declarative two-way data binding, computed properties, automatically-updating templates powered by its own template library, HTMLBars, built on top of Handlebars.js, and a router for managing application state.
Routes
The router is a core concept of Ember, emphasizing the importance of the URL in managing application state. A route object corresponds to a URL and essentially serializes the application's current state. Routes are defined in the singleton Router object.
Models
Every route has an associated model, containing the data associated with the current state of the application. While one can use jQuery to load JSON objects from a server and use those objects as models, most applications use a model library such as Ember Data to handle this.
Controllers
Controllers are used to decorate models with display logic.It was typical for a controller to inherit from ObjectController if the template was associated with a single model record and ArrayController if the template was associated with a list of records. However, ObjectController and ArrayController have been deprecated in favor of explicitly accessing of the model property of Ember.Controller.[citation needed]
Templates
Templates are written with the HTMLBars templating language (a variation on the Handlebars template system) to describe the user interface. Templates are used to build the application's HTML and embed dynamically-updating expressions.
Views
Views are used to add sophisticated handling of user events, custom graphics not made with CSS, JavaScript animations, or reusable behavior to a template.
Components
Components are a specialized view for creating custom elements that can be easily reused in templates. The Ember Components implementation conforms as closely as possible to the W3C Web Components specification.
Ember Data
Most Ember.js applications use Ember Data, a data persistence library that maps client-side models to server-side data, although it is also possible to use Ember.js without Ember Data. By default, Ember Data can load and save records and their relationships without any configuration via a RESTful JSON API that follows certain conventions,providing many of the facilities of an ORM, but it is also easily configurable and can work with any server through the use of adapters. Ember Data is currently in beta and its API should not be considered stable until version 1.0.
Good Work!! :)
ReplyDelete