
Security News
US Government Forces Anthropic to Pull Claude Fable Days After Launch
Anthropic says the directive cited national security concerns over a narrow jailbreak, but offered no specific technical details.
@berlitz/form
Advanced tools
Creates a form from a provided schema.
yarn add @berlitz/form
| Argument | Type | Required | Default | Notes |
|---|---|---|---|---|
| action | string | ✅ | Added to the action attribute on the <form> element. Useful for making forms work when Javascript is disabled. | |
| fields | array | ✅ | Schema for generating the form fields. Refer to the proptypes for the required shape. | |
| onSubmit | function | ✅ | Callback used to handle form submission. onSubmit(values, setSubmitting, setStatus, resetForm) | |
| enableReinitialize | boolean | ❌ | true | Sets the Formik enableReinitialize prop. More info https://tinyurl.com/rzwvmhr |
| method | string | ❌ | 'post' | Sets the method attribute on the <form> element. |
| hiddenFields | array | ❌ | Schema for generating hidden form fields. | |
| light | boolean | ❌ | false | Sets the background to a solid colour and changes all labels and text in the form to be light. |
| loadingLabel | string | ❌ | 'Loading' | Text for the submit button when it is loading. |
| onChange | function | ❌ | Callback used to handle form changes. onChange(values) | |
| submitLabel | string | ❌ | 'Submit' | Text for the submit button. |
| termsLabel | string | ❌ | Text for a Terms and Conditions checkbox. The checkbox will not show if no text is provided. | |
| submitButtonRef | object | ❌ | A ref that is passed to the <SubmitButton /> on this form. Useful for triggering submit events outside of this component. | |
| hideSubmitButton | boolean | ❌ | Useful in combination with submitButtonRef for showing a custom submit button outside of this component. |
import Form from '@berlitz/form'
<Form
action="/"
onSubmit={(values, setSubmitting) => {
alert(values)
setTimeout(() => {
setSubmitting(false)
}, 2000)
}}
submitLabel="Find out more"
fields={fields}
hiddenFields={hiddenFields}
termsLabel="I accept the terms"
onChange={values => {
setValues(values)
}}
light
/>
FAQs
Form component for the Max Design System
We found that @berlitz/form demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Security News
Anthropic says the directive cited national security concerns over a narrow jailbreak, but offered no specific technical details.

Security News
A network of 152 Chrome live wallpaper extensions hid ad tracking and made extension-driven traffic look like Google search clicks.

Company News
Socket’s first CISO brings deep experience securing high-growth SaaS companies as open source supply chain threats accelerate.