global filter ignores other columns

I am using react-table like this:
function Table({ data, columns }) {
  const [sorting, setSorting] = useState<SortingState>([
    {
      id: "id",
      desc: true,
    },
  ]);
  const [globalFilter, setGlobalFilter] = useState("");

  const table = useReactTable({
    data,
    columns,
    state: {
      globalFilter,
      sorting,
    },
    onSortingChange: setSorting,
    onGlobalFilterChange: setGlobalFilter,
    getCoreRowModel: getCoreRowModel(),
    getSortedRowModel: getSortedRowModel(),
    getFilteredRowModel: getFilteredRowModel(),
  });
// ...
}

What I do not understand is why the global filter ONLY works with the column "id" but when I type "Peter" in my global filter input, I get nothing/table is removed, even if I have a user called "Peter".

I mean I can see the columns firstName and lastName but the global filter is ignoring them
Was this page helpful?