easy-forms
Form components

Text

Single-line text input — also password, tel, and url via inputType.

Stores a string. The most common control.

Preview
Live

Options

PropTypeDefaultDescription
placeholderstringPlaceholder text.
maxLengthnumberMaximum character count.
capitalize'upper' | 'lower' | 'title'Transform the value as the user types.
prefixstringStatic text shown before the input (e.g. "@").
suffixstringStatic text shown after the input.
inputType'text' | 'password' | 'tel' | 'url''text'The underlying HTML input type.

Validators

required, minLength, maxLength, pattern, and custom. See Validation.

On this page