How to map undefined boolean checkbox to false on AG Grid?

39 Views Asked by At

Im using static headers on my ag grid, and there are some headers/columns who can have values or not. When I get the data from the backend, the values for those headers may or may not come. However, when using AG Grid cell data type boolean, if the value is undefined it shows a grey checkbox, and i want it to be an empty/false checkbox instead, does anyone have an idea for that?

Left are undefined checkboxes and right are false/true checkboxes Image

I've tried to create a custom cell renderer, however I'm also having trouble on applying it on only boolean cell data types and not on everything else. Also I can't apply the cellRenderer on whatever data I want since even though this grid has static headers, some others might come from backend, so if I use this custom cell renderer i need to check if the cell datatype is boolean and only then apply it.

0

There are 0 best solutions below