Wednesday, 15 May 2019

how to keep track of components when navigating in dynamic component loading

We have 3 basic navigations which show hide Tab view tab1, tab2, tab3. Beside this, there is navigation from sidenav.

Each tab load component dynamically, and thus we navigate from one component to another.

Second, when navigation from one component to another component ends and user clicks on Done button, it should land on the tab1/tab2/tab3 whichever were initially open in DOM(ie end of navigation and landing on tab1/tab2/tab3 view), when component navigation started.

We can't load previous component whenever we navigate backwards because each component is utilized by different components and may be part of different navigational flow.

Here, routing is not involved only component loading into view.

Is there angular way to achieve this, considering given scenario?

Here, is the stackblitz link:

https://stackblitz.com/edit/angular-basic-starter-dfqnp3?file=src/app/app.component.ts



from how to keep track of components when navigating in dynamic component loading

No comments:

Post a Comment