# "Building an Ember.js Application" video too far out-of-date?

**URL:** <https://discuss.emberjs.com/t/building-an-ember-js-application-video-too-far-out-of-date/7286>\
**Category:** Uncategorized\
**Created:** [February 10, 2015, 4:19pm UTC](https://discuss.emberjs.com/t/building-an-ember-js-application-video-too-far-out-of-date/7286 "2015-02-10T16:19:11Z")\
**Posts on this page:** 6\
**Page:** 1

<div class="post-metadata">

**Author:** ![chipk](https://avatars.discourse-cdn.com/v4/letter/c/bc8723/32.png) [@chipk](https://discuss.emberjs.com/u/chipk)\
**Post date:** [February 10, 2015, 4:19pm UTC](https://discuss.emberjs.com/t/building-an-ember-js-application-video-too-far-out-of-date/7286/1 "2015-02-10T16:19:11Z")

</div>

Hi folks - new Ember developer here. I’ve used Tom’s intro blog-building video and app to get started with Ember and it’s been very helpful. The app uses

> {{#each model}}

and I noticed the deprecation message on moving from the context-switching form to the keyword form. However, modifying the code to use

> {{#each post in posts}}

and referencing

> {{post.title}}

in the loop isn’t generating any output. But the demo app also doesn’t define the post or posts models - e.g.

> App.Posts = DS.Model.extend()

so I’m wondering if this too is an aspect of the demo video/app that’s out of sync with v1.9.1 ? Poking around, I was able to get the form

> {{#each post in model}}

to work, but would like to understand what is necessary to use

> {{#each post in posts}}

Thanks.

---

<div class="post-metadata">

**Author:** ![splattne](https://sea1.discourse-cdn.com/flex019/user_avatar/discuss.emberjs.com/splattne/32/3694_2.png) [@splattne](https://discuss.emberjs.com/u/splattne)\
**Post date:** [February 10, 2015, 6:30pm UTC](https://discuss.emberjs.com/t/building-an-ember-js-application-video-too-far-out-of-date/7286/2 "2015-02-10T18:30:02Z")

</div>

You could alias `model` to `posts` it in your controller:

```
posts: Ember.computed.alias('model')

```

---

<div class="post-metadata">

**Author:** ![chipk](https://avatars.discourse-cdn.com/v4/letter/c/bc8723/32.png) [@chipk](https://discuss.emberjs.com/u/chipk)\
**Post date:** [February 10, 2015, 7:02pm UTC](https://discuss.emberjs.com/t/building-an-ember-js-application-video-too-far-out-of-date/7286/3 "2015-02-10T19:02:16Z")

</div>

Thanks @splattne - Tom’s video demo app didn’t define a posts controller, so creating it and adding your alias definition did allow

> {{#each post in posts}}

to work. But this seems like a workaround to fill in for some other piece I must be missing, no? i.e. I wouldn’t expect to need to manually alias ‘posts’ since it is already named as a resource in the router, and the controller itself is named PostsController. Any further thoughts? Thanks.

---

<div class="post-metadata">

**Author:** ![splattne](https://sea1.discourse-cdn.com/flex019/user_avatar/discuss.emberjs.com/splattne/32/3694_2.png) [@splattne](https://discuss.emberjs.com/u/splattne)\
**Post date:** [February 10, 2015, 7:09pm UTC](https://discuss.emberjs.com/t/building-an-ember-js-application-video-too-far-out-of-date/7286/4 "2015-02-10T19:09:02Z")

</div>

If this is the code:

[https://github.com/tildeio/bloggr-client/blob/master/js/app.js](https://github.com/tildeio/bloggr-client/blob/master/js/app.js)

It looks like `posts` is just a global variable as dummy data for this little example app.

---

<div class="post-metadata">

**Author:** ![chipk](https://avatars.discourse-cdn.com/v4/letter/c/bc8723/32.png) [@chipk](https://discuss.emberjs.com/u/chipk)\
**Post date:** [February 10, 2015, 7:38pm UTC](https://discuss.emberjs.com/t/building-an-ember-js-application-video-too-far-out-of-date/7286/5 "2015-02-10T19:38:34Z")

</div>

I’ve replaced the global ‘posts’ with a JSON api call inside the PostsRoute router, as Tom did in the video.

That said, the real question here has to do with the description of named-parameter {{#each}} helpers described under “MORE CONSISTENT HANDLEBARS SCOPE” [found here](http://emberjs.com/guides/deprecations/#toc_more-consistent-handlebars-scope)

The examples suggest that a named model - i.e. ‘posts’ rather than ‘model’ - is standard, so I’m wondering why you would have to explicitly create an alias for “model” inside the controller when “posts” is already named as part of that controller name, as well as the names of the route and the template? I would expect Ember to know the model’s name at the point it is being referenced inside {{#each}} within the ‘posts’ template and the examples at the link above suggest that to me as well. It seems like maybe i’m not understanding something fundamental about the Ember architecture?

---

<div class="post-metadata">

**Author:** ![kgish](https://sea1.discourse-cdn.com/flex019/user_avatar/discuss.emberjs.com/kgish/32/13333_2.png) [@kgish](https://discuss.emberjs.com/u/kgish)\
**Post date:** [February 11, 2015, 12:16pm UTC](https://discuss.emberjs.com/t/building-an-ember-js-application-video-too-far-out-of-date/7286/6 "2015-02-11T12:16:21Z")

</div>

I agree that it’d be nice if the video could be updated as it could be confusing for newbies.
