I have two components: Component 1 and Component 2
Component 2 can be accessed via Component 1, from a button:
<ion-button [routerLink]="['/urlofComponent1'] [color]="'white'">Request </ion-button>
I have set a function in Component 2, to redirect user to 'Component 1' on page refresh, via:
this.router.navigate(['/urlofComponent1']);
When component 2 is already opened and page is refreshed, user is redirected to Component 1.
When I access Component 2 now, via the button, ngOnit() of Component 2 is not called.
Any suggestions?