Citizen Developer here trying to figure this out. I have my array and I have no problem getting what I need using the accessorFn... but in the cell render I'm trying to populate a variable that is in another object and not in the data array used to by the react-table.
const defaultColumns = [
{
accessorKey: "Traveler",
header: "Traveler",
accessorFn: (row) => `${row.LTAGNAME} ${row.FTAGNAME} (${row.EMPNUM})`,
cell: (props) => (
<Link to={`/${group.ID}/registrant/${props.row.original.id}`}>
{props.getValue()}
</Link>
),
size: 290,
},
{group.ID} is a separate object in React unrelated to the data being passed into the useReactTable function. Is it possible to reference something outside of the "data"