title: Formik + Yup blur all the fields even if only one field is touched in react native
body: <p>I created form in react native using following tutorial <a href="https://blog.jscrambler.com/creating-and-validating-react-native-forms-with-formik" rel="nofollow noreferrer">https://blog.jscrambler.com/creating-and-validating-react-native-forms-with-formik</a></p>
  <p>This is working fine but there is only one problem. I have 5 fields firstname, lastname, email, password, confirmpassword. If I touch the firstname field and as I leave this filed Formik invalidate all the field. I didn't touch other field but it is validating other fields as well.</p>
  <pre><code>&lt;Formik
          validationSchema={SignupSchema}
          initialValues={{
              firstName: '',
              lastName: '',
              email: '',
              password: '',
              confirmPassword: ''
          }}
          onSubmit={postCreateHandler}
      &gt;
          {({ handleChange, handleBlur, handleSubmit, values, errors, touched, isSubmitting }) =&gt; (
  &lt;View style={LoginStyle.loginFormWrapper}&gt;
  &lt;View&gt;
      &lt;InputText
          label=&quot;First Name&quot;
          placeholder='First Name'
          autoCapitalize=&quot;words&quot;
          autoComplete=&quot;name&quot;
          keyboardType=&quot;default&quot;
          returnKeyType='next'
          returnKeyLabel='next'
          value={values.firstName}
          onChangeText={handleChange('firstName')}
          onBlur={handleBlur('firstName')}
          error={errors.firstName}
          touched={touched.firstName}
          ref={firstNameRef}
          onSubmitEditing={() =&gt; lastNameRef.current?.focus()}
      /&gt;
  &lt;/View&gt;
  &lt;View&gt;
      &lt;InputText
          label=&quot;Last Name&quot;
          placeholder='Last Name'
          autoCapitalize=&quot;words&quot;
          autoComplete=&quot;name&quot;
          keyboardType=&quot;default&quot;
          returnKeyType='next'
          returnKeyLabel='next'
          value={values.lastName}
          onChangeText={handleChange('lastName')}
          onBlur={handleBlur('lastName')}
          error={errors.lastName}
          touched={touched.lastName}
          ref={lastNameRef}
          onSubmitEditing={() =&gt; emailRef.current?.focus()}
      /&gt;
  
  &lt;/View&gt;
  &lt;View&gt;
      &lt;InputText
          label=&quot;Email&quot;
          placeholder='Email'
          autoCapitalize='none'
          autoCompleteType='email'
          keyboardType='email-address'
          returnKeyType='next'
          returnKeyLabel='next'
          value={values.email}
          onChangeText={handleChange('email')}
          onBlur={handleBlur('email')}
          error={errors.email}
          touched={touched.email}
          ref={emailRef}
          onSubmitEditing={() =&gt; passwordRef.current?.focus()}
      /&gt;
  &lt;/View&gt;
  &lt;View&gt;
      &lt;InputText
          label=&quot;Password&quot;
          value={values.password}
          placeholder='Password'
          autoCapitalize='none'
          autoCompleteType='password'
          returnKeyType='next'
          returnKeyLabel='next'
          onChangeText={handleChange('password')}
          onBlur={handleBlur('password')}
          error={errors.password}
          touched={touched.password}
          onSubmitEditing={() =&gt; confirmPasswordRef.current?.focus()}
      /&gt;
  &lt;/View&gt;
  &lt;View&gt;
      &lt;InputText
          label=&quot;Confirm Password&quot;
          value={values.confirmPassword}
          placeholder='Confirm Password'
          autoCapitalize='none'
          autoCompleteType='password'
          returnKeyType='go'
          returnKeyLabel='go'
          onChangeText={handleChange('confirmPassword')}
          onBlur={handleBlur('confirmPassword')}
          error={errors.confirmPassword}
          touched={touched.confirmPassword}
          ref={confirmPasswordRef}
      /&gt;
  &lt;/View&gt;
  &lt;View style={{ marginVertical: 25 }}&gt;
      &lt;Button
          mode=&quot;contained&quot;
          style={buttonStyle}
          labelStyle={buttonLabelStyle}
          onPress={handleSubmit}
      &gt;
          Submit
      &lt;/Button&gt;
  &lt;/View&gt;
  &lt;/View&gt;
  </code></pre>
  <p>Yup Validation Schema is as follows:</p>
  <pre><code>const SignupSchema = Yup.object().shape({
  firstName: Yup.string()
      .min(2, 'Too Short!')
      .max(25, 'Too Long!')
      .required('Required'),
  lastName: Yup.string()
      .min(2, 'Too Short!')
      .max(25, 'Too Long!')
      .required('Required'),
  email: Yup.string().email('Invalid email').required('Required'),
  password: Yup.string()
      .min(8, 'Too Short!')
      .required('Required'),
  confirmPassword: Yup.string()
      .required('Required')
      .oneOf([Yup.ref('password'), null], 'Passwords must match')
  
  });
  </code></pre>