Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

"Submitting" form state is replaced with "Valid" straight away #236

Open
alexeygolev opened this issue May 17, 2022 · 4 comments
Open

"Submitting" form state is replaced with "Valid" straight away #236

alexeygolev opened this issue May 17, 2022 · 4 comments
Assignees

Comments

@alexeygolev
Copy link

I've just noticed that #218 introduced a line that sends a SetFormState(Valid) action immediately after sending the Submit action. Not sure what the purpose of the change is but it results in no Submitting state. I noticed it because I disable the submit button on submit and it's no longer being disabled. If I log formState on render it stays Valid up until the form is successfully submitted. Is this intentional?

self.send(SetFormState(Valid))

@vmarcosp
Copy link
Member

vmarcosp commented Jul 1, 2022

Hey @alexeygolev thanks for reporting. It's not intentional and i'ts probably a bug. I'll test the behavior and ping you with a better explanation for this issue.
cc @fakenickels

@vmarcosp
Copy link
Member

vmarcosp commented Jul 1, 2022

And sorry for the delay, it has been a busy month.

@fakenickels
Copy link
Member

Hey thanks for bringing this up. It definitively sounds like a bug

@fakenickels
Copy link
Member

It should put the form in Valid state then Submitting. I took a quick look in the code and not sure what can be causing it to not be working normally

@vmarcosp vmarcosp self-assigned this Jul 10, 2022
haflinger pushed a commit to haflinger/reform that referenced this issue Nov 7, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants