T
TanStack3y ago
gradual-turquoise

Symbols for boolean values

hello, i've got a column that is configured like this:
{
accessorFn: row => Boolean(row.ethernet),
id: 'ethernet',
header: () => 'Ethernet',
footer: props => props.column.id,
},
{
accessorFn: row => Boolean(row.ethernet),
id: 'ethernet',
header: () => 'Ethernet',
footer: props => props.column.id,
},
is it possible to transform the boolean values into unicode symbols?
1 Reply
gradual-turquoise
gradual-turquoiseOP3y ago
i finally solved it myself:
{
accessorFn: (row) => Boolean(row.ethernet),
id: "ethernet",
header: () => 'Ethernet',
cell: (row) => {
let x = Boolean(row.getValue()) ? symbol-true : symbol-false;
return x;
},
},
{
accessorFn: (row) => Boolean(row.ethernet),
id: "ethernet",
header: () => 'Ethernet',
cell: (row) => {
let x = Boolean(row.getValue()) ? symbol-true : symbol-false;
return x;
},
},

Did you find this page helpful?