Skip to content

Instantly share code, notes, and snippets.

@rwjblue
Forked from taras/route.redirect.js
Created October 3, 2013 16:51
Show Gist options
  • Save rwjblue/6813071 to your computer and use it in GitHub Desktop.
Save rwjblue/6813071 to your computer and use it in GitHub Desktop.
App.IndexRoute = Ember.Application.extend({
redirect: function(transition) {
this.transitionTo('movies');
}.before('model') // execute before model hook
});
App.IndexRoute = Ember.Application.extend({
redirect: function(model, transition) {
this.transitionTo('movies', model);
}.after('model') // execute after model hook
});
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment