I am trying to debug a javascript problem, but the problem happens when submitting a form. I see a javascript error briefly in the console window, then the form gets submitted.
Is there a way to make the default not to submit the form, so I can see the script error before I get sent to the form submit page?
The code is using jquery with a
$('#form').on('submit', function() {
// validation code with script error somewhere
});
return false;return false;is overkill for this situation.