A component responsible for form data separation on the layout level. Designed primarily for handling of complex forms and semantic representation of fields structure expected by a remote end-point.
Beware that grouping the fields affects how you reference them in the serialized object, or reactive resolvers.
Props
Prop name
Type
Description
name
string
The name of the field group. All the fields wrapped in Field.Group will be available by the following reference path: [...groupNames, fieldName].
exact
boolean
Prevents group names concatenation due to inheritance.
One of the benefits of Field.Group is an ability to have multiple groups with the same name, which will group the elements under one property upon the serialization. This is particularly useful when UI was not, or cannot be designed according to the data structure expected by the remote end-point.
It is possible to opt-out the Nested groups behavior by providing the exact prop to the Field.Group that needs to be escaped. The nesting of the field group then has no effect over the serialized path.
{"billingAddress": {"firstName":"John","lastName":"Maverick"// no "userInfo" sub-group },"userInfo": {"firstName":"Kate","lastName":"Rosewood",// exact "userInfo" was merged as split groups"phoneNumber":"+123" }}