fix(angular): ensure all NavigationExtras values are preserved when navigating (#18468)

fixes #18469
This commit is contained in:
Mark Levy
2019-06-10 17:45:36 +02:00
committed by Liam DeBeasi
parent 54bdb367c2
commit 7610787e09

View File

@ -202,7 +202,12 @@ export class NavController {
urlTree.fragment = options.fragment; urlTree.fragment = options.fragment;
} }
return this.router!.navigateByUrl(urlTree); /**
* `navigateByUrl` will still apply `NavigationExtras` properties
* that do not modify the url, such as `replaceUrl` which is why
* `options` is passed in here.
*/
return this.router!.navigateByUrl(urlTree, options);
} }
} }
} }