Angular variable into routerLink
There you go.
<a [routerLink]="['/details', data.id]"> Link </a>
Parameters go as second item in the array syntax to router link, like this:
[routerLink]="['/details', data.id]
Read more here
Similar to above, but you can also do this:
<a [routerLink]="['/details' + data.id]"> Link </a>