I've tried below but it changes the background colour of whole column.
Code: Select all
<p-dataTable [value]="account" >
<p-column field="description" [sortable]="true" style="{'background':'#00b3ee'}">
<template pTemplate="header">
<span>Description</span>
</template>
</p-column>
</p-dataTable>
I have found the primeng class which I can modify to achieve what I want.
Code: Select all
.ui-datatable .ui-datatable-thead > tr > th {
font-weight: normal;
background: aliceblue;
}
Is there some way to achieve this?