JoeyDye
4/29/2020 - 7:31 PM

Form Scroll and Focus

 headerBtn.addEventListener('click', function(e) {
      e.preventDefault();
      
      // Focus user into form
      document.querySelector("input[id='FirstName']").focus();

      // Scroll to form
      document.getElementById('register').scrollIntoView()

    })