canSubmit is true in onSubmit validator
I'm wondering why canSubmit is true when I choose onSubmit validation. Shouldn't be false because the form is not valid?
2 Replies
wise-white•10mo ago
Yes
absent-sapphire•10mo ago
Using the
onMount
validator you can validate your form when it mounts and set it to invalid if needed - that way canSubmit
will be false
onSubmit runs after you submitted the form