@tannerlinsley@tan_stack
What's the recommended pattern for required fields that must start as undefined?
E.g. a required Date picker or enum select with no sensible default. Setting defaultValues: { endDate: undefined } makes the inferred field type undefined, not Date.
...
Two workarounds I've found, both feel ugly:
1. defaultValues satisfies Partial<X> as unknown as X — lies to the type system as forces full partial
2. Weaken the schema (z.string().refine(...) instead of z.enum, https://t.co/3NRh54mbSS() instead of https://t.co/WdDgM774cQ())
@shadcn@shadcn This is super helpful. Do you have any thoughts on the field.AppField usage and how to remove a lot of repition on the fields you are using (obviously super easy with things like input but what about something like RadioGroup?)