Skip to content

Commit

Permalink
system/many-array: Adjust code samples to ember-cli
Browse files Browse the repository at this point in the history
  • Loading branch information
Turbo87 committed Jun 5, 2015
1 parent 09b20c7 commit 36ee20c
Showing 1 changed file with 9 additions and 3 deletions.
12 changes: 9 additions & 3 deletions packages/ember-data/lib/system/many-array.js
Original file line number Diff line number Diff line change
Expand Up @@ -21,12 +21,18 @@ var map = Ember.EnumerableUtils.map;
an inverse. For example, imagine the following models are
defined:
```javascript
App.Post = DS.Model.extend({
```app/models/post.js
import DS from 'ember-data';
export default DS.Model.extend({
comments: DS.hasMany('comment')
});
```
```app/models/comment.js
import DS from 'ember-data';
App.Comment = DS.Model.extend({
export default DS.Model.extend({
post: DS.belongsTo('post')
});
```
Expand Down

0 comments on commit 36ee20c

Please sign in to comment.