Getting the type for the "to" prop - TanStack