Cliking on toggle button wont reset input field vanilla js

when Clicking on newsletter button, it shows a form subscription user will input email but if they decide not to they will click on the toggle button, but email still there need to clear the form. need to clear or reset the input field. Need help trying to reset

Try document.getElementById('letterSign').value = ''; in your event listener.

thanks!!! it worked althouth i found two more solutions to it:

  1. reset the form with .reset
  2. reset with the value = “”; on the else statement

thanks that one worked as well…