Esc
Documentation
On this page

Props

PropTypeDefaultDescription
schema requiredz.ZodTypeAnyNoneZod schema defining form fields
fieldsreadonly PageNode[]NoneOptional custom field nodes
onSubmit requiredActionTarget | { readonly kind: "action"; readonly id: string }NoneAction triggered on form submission
submitLabelstringNoneSubmit button text

Example

ts
Form({
  schema: z.object({ name: z.string().min(1), endpoint: z.string().url() }),
  onSubmit: createConnection(),
  submitLabel: "Connect",
})

View the source on GitHub