Closed ghost closed 6 years ago
In my opinion the following pattern would be better, as the component knows nothing about any routing information and everything is encapsulated in the routing module:
I agree completely. However, I do believe in some cases you may still want the whole transition in your component. This is also important for a migration guide if somebody's existing code already injected and used $transition$
.
My version of UI-Router is: 1.0.14
General Query
I've a question regarding accessing $transition$ within a route to component scenario.
According the following guide you recommend binding the $transition$ object to the component:
In my opinion the following pattern would be better, as the component knows nothing about any routing information and everything is encapsulated in the routing module: