title: How to ensure focused input retains visibility when on-screen keyboard is activated
body: <p>While building a mobile-first website, I have run into the common problem where an input element may be covered by the on-screen keyboard on a mobile device when it is activated.</p>
  <p>If I were building a native app with React Native, I could use <code>KeyboardAvoidingView</code>:</p>
  <blockquote>
  <h3>KeyboardAvoidingView</h3>
  <p>It is a component to solve the common problem of views that need to move out of the way of the virtual keyboard. It can automatically adjust either its position or bottom padding based on the position of the keyboard.</p>
  <p><sup>- <a href="https://facebook.github.io/react-native/docs/keyboardavoidingview" rel="nofollow noreferrer">https://facebook.github.io/react-native/docs/keyboardavoidingview</a></sup></p>
  </blockquote>
  <p>How can I ensure that the focused input remains visible when the on-screen keyboard is activated?</p>
  <p>I considered listening to the <code>resize</code> event on the window and focusing the last focused input, but I'm not sure what side effects this may have nor if it is a viable solution.</p>