You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Even with the above patch this does not work because formGroup is being used as a directive. It gets executed when the form element is created but before the MyFields elements exist (or at least that's my understanding). I was able to work around this by not using formGroup as a directive but instead calling it from onMount with a ref to the form.
I was just about to post a similar issue. Had a working form, but started to wrap my pairs in divs to apply styling. Form breaks. Validation doesn't work and values of inputs just show as blank. This seems like odd behavior to me as wrapping these elements in a div is a pretty standard practice.
Thanks for creating this library. While testing I have come across a couple of related issues.
Form fields do not work if nested in other elements
e.g. An
input
in adiv
will not be seen by theformGroup
function.This was solved by adding a couple of lines to the bottom of the
formGroup
function to recurse through elements...Form fields do not work if nested in custom Solid components.
e.g.
Even with the above patch this does not work because
formGroup
is being used as a directive. It gets executed when the form element is created but before theMyFields
elements exist (or at least that's my understanding). I was able to work around this by not usingformGroup
as a directive but instead calling it fromonMount
with aref
to theform
.Maybe worth mentioning in the docs if there isn't a better solution?
The text was updated successfully, but these errors were encountered: