5.3.0






Form

The form kit provides consumers with a convenient, consistently styled <form> wrapper.

Form Helpers

There are currently two form helper options for Rails: form_with and simple_form.

Note: It is suggested to use form_with for newer or more progressive Rails applications and simple_form for older legacy forms where simple_form is already implemented and a complete overhaul might not make sense.

This kit does make use of other kits such as text_input, select and typeahead to name a few. Doing so provides UI consistency within forms and makes adding a form to your page easier.

Default (Form With)


Default (Form With) + Validation


Validation displays an error with red border and red text below indicating that the user must fill out the field.

Default (Simple Form)


Default (Simple Form) + Validation


Validation displays an error with red border and red text below indicating that the user must fill out the field.


Things to Avoid

Avoid using a form without validation if fields are required and using with validation if not required.

Available Props
form_system
form_system_options
children
validate