If you have url like https://myapp.com/owner/123/show?height=23 then use
combineLatest( [this.route.paramMap, this.route.queryParamMap] )
.subscribe( ([pathParams, queryParams]) => {
let ownerId = pathParams.get('ownerId'); // =123
let height = queryParams.get('height'); // =height
// ...
})
In case when you use this.router.navigate([yourUrl]);
and your query parameters are embedded in yourUrl
string then angular encodes a URL and you get something like this https://myapp.com/owner/123/show%3Fheight%323 - and above solution will give wrong result (queryParams will be empty, and query params can be glued to last path param if it is on the path end). In this case change the way of navigation to this
this.router.navigateByUrl(yourUrl);