TanStackT
TanStack2y ago
7 replies
nursing-lime

How to handle a nullable object in the form.

I have an object that is nullable but if I try to access it using <form.Field name="item.nullable_object"></form.Field> and it's null, an error is thrown.

Think as the structure like this:
type Item = {
  nullable_item: { id: string } | null;
}
Was this page helpful?