Can you conditionally render multiple forms within one Formik component #3143
Unanswered
tonyfatouros
asked this question in
Q&A
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Hi,
I am new to React and to Formik forms. At the moment I have my main/parent Formik form with initialValues of say five different fields, with one of those fields being a select list that determines which other forms to conditionally render as part of my main form.
My question is, based on my select-list value, which I have stored within state, is it possible to have multiple forms within the one Formik component as below and only render Form 2 below based on a select-list value in state?
If what I am asking here is not possible, could people please suggest another means of trying to achieve what I am after, keeping in mind that I will always need to have my main parent Formik form.
Beta Was this translation helpful? Give feedback.
All reactions