When using a form that contains nested resources it is necessary to ensure that the nested resources exist for the form builder to work appropriately.
I have seen this achieved in numerous ways – building them in the controller or building them in the view, but I have never seen a consistent approach.
If a form contains nested has_one
items, where should those items be built if they don't already exist on the model?