isValid state doesn't changed in mui material Dialog #7663
-
Hi all, guys! I facing strange behaviour. IsValid state doesn't change inside material . I am getting IsValid from useFormState hook. What am i doing wrong? Could you please help me? demo here |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 2 replies
-
I believe, it's something got to do with the |
Beta Was this translation helpful? Give feedback.
I believe, it's something got to do with the
<Dialog />
modal portal, that messes up the child components update on the form's state change in the Context.I'd suggest to move your form initialization inside the
<Dialog />
with the rest of your form. See this CSB for example