title: ref.current.focus() is not a function
body: <p>im trying to use a ref for focusing on the element when onBlur. I'm using react v.16.9.0
  My code is this:</p>
  <pre><code>const handleKeyDown = (e, element, index) =&gt; {
    element.current.focus();
    event.preventDefault();
  };
  
  const pinDigitBuilder = () =&gt; {
    const arr = Array(...Array(TOTAL_PIN_DIGITS));
    return arr.map((x, i) =&gt; {
      const inputRef = useRef(null);
      console.log(inputRef);
      return (
        &lt;Field
          key={`${PIN_DIGIT}${i + 1}`}
          id={`${PIN_DIGIT}${i + 1}`}
          name={`${PIN_DIGIT}${i + 1}`}
          ref={inputRef}
          component={InputTextField}
          className=&quot;text xxs2&quot;
          classNameInvalid=&quot;text xxs2 error&quot;
          type=&quot;text&quot;
          divClassName=&quot;fieldWrap&quot;
          maxLength={1}
          normalize={keepNumbersOnly}
          errorStyle={{ display: 'none' }}
          autoComplete=&quot;off&quot;
          onBlur={(e) =&gt; { handleKeyDown(e, inputRef, i); }}
        /&gt;
      );
    });
  };
  </code></pre>
  <p>When i click outside the field an error occured saying that element.current.focus();. I dont get it. I use useRef as explained with details in the docs and i dont know what im missing. Any ideas?</p>