1👍
✅
It sounds like your form submit button is actually submitting the form and the click event is not called. Looking at your code I would say that e.preventDefault
should be e.preventDefault()
otherwise the default form submit is not “prevented”.
Source:stackexchange.com