Closed solebared closed 2 years ago
Enhances fieldNameWithPrefix utility function so it can support multiple segments in the field name.
fieldNameWithPrefix
Mostly wanted to rescue this useful change from a wip branch that probably won't get merged in.
Renames the function as composeFieldName and makes the implementation recursive.
composeFieldName
In combination with the partial function, allows components to generate field names for deeply nested attributes.
partial
Enhanced existing unit test.
Why
Enhances
fieldNameWithPrefix
utility function so it can support multiple segments in the field name.Mostly wanted to rescue this useful change from a wip branch that probably won't get merged in.
What
Renames the function as
composeFieldName
and makes the implementation recursive.In combination with the
partial
function, allows components to generate field names for deeply nested attributes.Testing
Enhanced existing unit test.
Pre-Merge Checklist