In my angular web application need to remove a page reference from angular page history stack . Ex : i navigate from login page to dashboard page now should remove login page reference from stack.
I think you need to look in to https://angular.io/api/router/NavigationExtras#replaceUrl
You need to pass replaceUrl: true when navigating to component, as per doc:
Navigates while replacing the current state in history.
// Navigate to /view
this.router.navigate(['/view'], { replaceUrl: true });
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With