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

I followd the demo. But got a error #1160

Closed
bodyno opened this issue Jun 14, 2016 · 11 comments
Closed

I followd the demo. But got a error #1160

bodyno opened this issue Jun 14, 2016 · 11 comments

Comments

@bodyno
Copy link

bodyno commented Jun 14, 2016

Uncaught Error: You must either pass handleSubmit() an onSubmit function or pass onSubmit as a prop

Like this.
How can I do with it

@erikras
Copy link
Member

erikras commented Jun 14, 2016

What demo? Show your code.

@bodyno
Copy link
Author

bodyno commented Jun 14, 2016

It's here
http://redux-form.com/5.2.5/#/examples/simple?_k=uz3p2z

I just follow this.
But got this error on my code.
Everything is all right.
Only on me click the submit button.
Then show:
Uncaught Error: You must either pass handleSubmit() an onSubmit function or pass onSubmit as a prop

@callmephilip
Copy link

@bodyno
Copy link
Author

bodyno commented Jun 15, 2016

Even this throw an error
https://github.com/thebakeryio/redux-form-issue
Why?
I didn't touch anything
@callmephilip

@callmephilip
Copy link

@erikras any thoughts on this?

@gabrielpugliese-luizalabs

You guys can see the reproduction link in this issue (I've got another issue related):
#1165

@crittelmeyer
Copy link

Not sure if this is related, but I'm seeing the "You must either pass handleSubmit() an onSubmit function or pass onSubmit as a prop" error message when trying to run the 6.0.0-alpha asyncValidation example here: http://redux-form.com/6.0.0-alpha.15/examples/asyncValidation/

@erikras
Copy link
Member

erikras commented Jun 20, 2016

Well, the problem is exactly what the error message says it is. Suggestions for how to more clearly reword it are welcome.

I wish I could anchor-link directly to it, but scroll down to the handleSubmit section of the docs.

In the example, we are providing an onSubmit prop to the decorated form component.

Here's a PR to fix your example.

@erikras erikras closed this as completed Jun 20, 2016
@callmephilip
Copy link

Thanks for taking time to look into this, Erik. I think you should update 'Getting started' examples to reflect this (http://redux-form.com/5.2.5/#/getting-started?_k=uo5tq0) since they are currently misleading especially the That's it! There is no Step #3! part

@axe-z
Copy link

axe-z commented May 29, 2017

Yes I've been stuck for hours, all the steps should be there... this is ... Extremely misleading.none of the examples work, on for a first try, there is enough magic here to fuck with us..

@lock
Copy link

lock bot commented Jun 1, 2018

This thread has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs.

@lock lock bot locked as resolved and limited conversation to collaborators Jun 1, 2018
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

6 participants