Or build ember-data.js yourself. Clone the repository and run npm run build:production
after setup. You'll find ember-data.js in the dist directory.
Internet Explorer 8
Internet Explorer 8 is no longer supported by Ember Data on versions
2.0 and later.
If you require IE8 support, you can use the 1.13 series of releases.
The source code is available on the release-1-13 branch.
Internet Explorer 8 support requires Ember 1.8.1 (which provides a polyfill for Object.create).
Instantiating the Store
In Ember Data, the store is responsible for managing the lifecycle of
your models. Every time you need a model or a collection of models,
you'll ask the store for it.
To create a store, you don't need to do anything. Just by loading the
Ember Data library, all of the routes and controllers in your
application will get a new store property. This property is an
instance of DS.Store that will be shared across all of the routes and
controllers in your app.
Defining Your Models
First thing's first: tell Ember Data about the models in your
application. For example, imagine we're writing a blog reader app.
Here's what your model definition would look like if you're using
ES6 modules (via ember-cli):
Without immediately diving in to the depths of the architecture, one
thing you should know is that Ember Data uses an object called an
adapter to know how to talk to your server.
An adapter is just an object that knows how to translate requests from
Ember Data into requests on your server. For example, if I ask the Ember
Data store for a record of type person with an ID of 123, the
adapter translates that into an XHR request to (for example)
By default, Ember Data will use the JSONAPIAdapter, which adheres to the JSON-API spec.
To learn more about adapters, including what conventions the
various adapters follow and how to build your own, see the Ember.js
Guides: Customizing Adapters.
Fetching a Collection of Models
From your route or controller:
This returns a promise that resolves to the collection of records.
Fetching a Single Model
This returns a promise that resolves to the requested record. If the
record can't be found or there was an error during the request, the
promise will be rejected.