How to pass query parameters with a routerLink

QueryParams is routerLink where they can be passed like

<a [routerLink]="['/path']" [queryParams]="{id:'value'}">
 Details 
</a>

To pass query parameters to ts file.

this.router.navigate(['/path'], queryParams: { 'id': 'value'});
0 0 votes
Article Rating
Subscribe
Notify of
guest
0 Comments
Inline Feedbacks
View all comments