title: Check the render method of `Formik`
body: <p>I'm currently getting the following error with my React app:</p>
  <blockquote>
  <p>Error: Element type is invalid: expected a string (for built-in
  components) or a class/function (for composite components) but got:
  undefined. You likely forgot to export your component from the file
  it's defined in, or you might have mixed up default and named imports.</p>
  <p>Check the render method of <code>Formik</code>.</p>
  </blockquote>
  <p>I am getting this error because I am wrapping my Submit button in Apollo's <code>&lt;Mutation&gt;</code> component to enable me to post data to my graph database:</p>
  <pre><code>&lt;Mutation mutation={CREATE_EVENT} variables={eventID, values.eventName, null, null, values.favourite, values.broadcast}&gt;
    {postMutation =&gt; &lt;Button
      type=&quot;submit&quot;
      onClick={postMutation}
      disabled={isSubmitting}
      className={classes.saveMem}
    &gt;
      Save
  &lt;/Button&gt;}
  &lt;/Mutation&gt;
  </code></pre>
  <p>When I remove Apollo's <code>&lt;Mutation&gt;</code> component the Formik form renders as expected:</p>
  <pre><code>&lt;Button
      type=&quot;submit&quot;
      onClick={() =&gt; CreateMem(props.values.file, values)}
      disabled={isSubmitting}
      className={classes.saveMem}
    &gt;
      Save
  &lt;/Button&gt;
  </code></pre>
  <p>I'm unsure whether this is a bug with Formik or if there is another issue.</p>
  <p>I have seen a few other people seeing the same error message and they have found a solution by updating their version of <code>Formik</code>, <code>React</code> and <code>React-Dom</code>. I'm currently running the current versions of all of them:</p>
  <pre><code>&quot;formik&quot;: &quot;^2.1.5&quot;,
  &quot;react&quot;: &quot;^16.9.0&quot;,
  &quot;react-dom&quot;: &quot;^16.9.0&quot;,
  </code></pre>
  <p>The other thing I've seen suggested is to import <code>Forms</code> from <code>react-bootstrap</code> instead of from <code>Formik</code> but that doesn't seem to work either.</p>