Understanding the new router flow for nested routes


I’m trying to really grasp how the Ember routing works: Reading this article (yes, I know it is outdated, but I think it still provides value due to its depth)

If a url of /vault/new/step1 is requested, all three of these routes will be composed together and all 3 states or routes will be executed in sequence. Each connectOutlets method on each state or route will be executed, giving you a chance to change what is displayed on the page as the url changes and the application state changes.

So my question: Does this pattern still apply for the new routing mechanism? I haven’t seen any good description of the current router, as to exactly which methods are executed in which order on which class instances for a nested resource-route. If the above is still the case, in answers many of my concerns :slight_smile: Thanks!


As far as I understand, yes the gist of it still applies. @darthdeus wrote an excellent overview of the new router’s lifecycle that may be what you’re looking for: http://darthdeus.github.io/blog/2013/02/08/router-request-lifecycle/


It would be great to get this better documented. For example, where does the redirect call fall into that lifecycle? Is it called for every level or only the current route? How do you workaround the need to redirect based on the value of model when that is lazy loaded?


These sorts of posts should be part of the official docs, or at least there should be links to these articles from the official docs IMO, as long as the documentation is still valid…