T
TanStack13mo ago
absent-sapphire

How to change accessorKey value based on row value in table

{ accessorKey: "userId", header: ({ column }) => ( <DataTableColumnHeader column={column} title="User Id" /> ), cell: ({ row }) => ( <label>{row?.original?.subRetailerId ?? row?.original?.retailerId}</label> ), }, i want change accessorKey from "userId" to "userId2" when retailerId exists
0 Replies
No replies yetBe the first to reply to this messageJoin

Did you find this page helpful?