Skip to content

Latest commit

 

History

History
38 lines (33 loc) · 1.28 KB

File metadata and controls

38 lines (33 loc) · 1.28 KB
Forms Lab logo
Join the community on GitHub License

Getting Started

Formslab is an experiment in making forms in Next.js fun and easy. It is designed with a radically simple API and built with a DX-first philosophy.

A form in Formslab is created using simple-to-use, composable Lego-like components. For example:

<Form action={createUserProfile} required>
  <Page>
    <Input name="firstName" />
    <Input name="lastName" />
    <Address name="shipping" />
  </Page>
  <Page>
    <Checkbox
      name="sameShippingBilling"
      label="Billing address is same as shipping"
    />
    <Address name="billing" disabled="sameShippingBilling" />
    <h3>Municipality check</h3>
    <Radio name="isMunicipality" label="Are you a municipality?" />
    <Label
      className="text-red"
      label="Please provide a purchase order at checkout"
      visible="isMunicipality"
    />
  </Page>
</Form>