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
This seems to work for me as of Spring 2017:
goBack(): void { this.router.navigate(['../'], { relativeTo: this.route }); }
Where your component ctor accepts ActivatedRoute and Router, imported as follows:
ActivatedRoute
Router
import { ActivatedRoute, Router } from '@angular/router';