Created
May 29, 2013 03:54
-
-
Save timani/5667861 to your computer and use it in GitHub Desktop.
If you want to render two different templates into outlets of two different rendered templates of a route: - http://emberjs.com/guides/routing/rendering-a-template/ Ember.js
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
App.PostRoute = App.Route.extend({ | |
renderTemplate: function() { | |
this.render('favoritePost', { // the template to render | |
into: 'posts', // the template to render into | |
outlet: 'posts', // the name of the outlet in that template | |
controller: 'blogPost' // the controller to use for the template | |
}); | |
this.render('comments', { | |
into: 'favoritePost', | |
outlet: 'comment', | |
controller: 'blogPost' | |
}); | |
} | |
}); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment