Skip to content

Instantly share code, notes, and snippets.

@geminorum
Created March 25, 2022 06:29
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save geminorum/3ebe7e4d53c4cabcd904717405c7e611 to your computer and use it in GitHub Desktop.
Save geminorum/3ebe7e4d53c4cabcd904717405c7e611 to your computer and use it in GitHub Desktop.
form resetting jQuery to clear any values from `input` types that are not hidden and neither a `checkbox` nor `radio` type
$('input:not([type="checkbox"]):not([type="radio"]):visible, textarea:visible', form).val('');
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment