angular change url query params code example
Example: angular set url parameters
//in your HTML code :
<a href="javascript:;" routerLink="/link/params">
My link
</a>
// app-routing.module.ts:
//in your Routes array :
{path: '/link/:paramsName', component: MyComponent }