K
K
klinnov2016-09-23 18:15:41
JavaScript
klinnov, 2016-09-23 18:15:41

How to build a structure correctly?

Hello!
There is an angular application. There is a ui-router that switches pages.
But there is one problematic page where, in addition to the main controller, there should also be page tabs.
When you click on a tab, its view and controller are pulled up.
d3c22852c2.png
Now it's done - but with an overload and the main controller.
That is, now we clicked on the tab - there was a transition along the route, the view of the tab with the tab controller was pulled up + include view with the main controller.
Is there anything I can do to prevent the main controller from rebooting? It is also necessary that the path in the url changes as it is now.
Thank you!

Answer the question

In order to leave comments, you need to log in

1 answer(s)
A
Alexander Korotaev, 2016-09-23
@klinnov

Make nested routes for tabs, the parent controller, as well as its template, will not be reloaded in this case

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question