My problem is quite classic. I have a private part of an application which is behind a login form. When the login is successful, it goes to a child route for th
login form
add Location to your constructor from @angular/common
@angular/common
constructor(private _location: Location) {}
add the back function:
back() { this._location.back(); }
and then in your view:
Back