Form selector.
type FormField<
T extends string = string,
F extends Record<string, any> = Record<string, any>,
> = (ObjectValue<FormReference<T>> & F) | null;
type ContactForm = FormField<"contact">;
// Result: {
// handle: "contact";
// title: string;
// api_url: string;
// } | null
type AllowedForms = FormField<"contact" | "newsletter">;
// Result: {
// handle: "contact" | "newsletter";
// title: string;
// api_url: string;
// } | null
type NewsletterForm = FormField<"newsletter", { email: string }>;
// Result: {
// handle: "newsletter";
// title: string;
// api_url: string;
// email: string;
// } | null