Behive Tech Registry

Form Field Managed

v0.1.2

`FormField` with its react-hook-form wiring already done — the control's value/onChange/onBlur/ref, the label association, and the error message.

pnpm add @behivetech/forms.form-field-managed

One managed form covering both integration shapes: a native control, where the field spreads straight on, and two Radix controls, where the caller maps the one prop that differs. Each field passes `control` rather than naming type parameters. That is the shape worth copying: it infers both parameters, so `field.value` is the type of that one field and needs no cast. Reading `control` from context instead works too, but then the field type has to be named — `<FormFieldManaged< DemoValues, "email">` — because supplying one type argument stops TypeScript inferring the other.

Managed Form