The link I am trying to render looks like this when I just try to render it on a basic HTML page:
<a [routerLink]="['/leverance/detail', 13]">A new link</a>
When trying to render it on the ag-Grid, I try to do like below:
src\app\leverancer\leverancer.component.ts
ngOnInit() {
this.dataGridColumnDefs = [
{
headerName: 'Type',
field: 'leveranceType.name',
width: 150,
cellRenderer: this.customCellRendererFunc
}
];
}
customCellRendererFunc(params): string {
const cellContent `<a [routerLink]="['/leverance/detail', 13]">A new link</a>`;
return cellContent;
}
but I don't see a working routerLink in my ag-Grid. Can you tell me what I need to do to render a working routerLink in my ag-Grid?