how to handle lists - TanStack