Field Level Validation Validator is not a function
See original GitHub issueHi, I have a simple signup form component and Im trying to use field level validation on each field. Everytime I pass validate
prop on any field, I get this weird error. I’m using next js for server-rendering.
TypeError: validator is not a function
at getError (http://localhost:3000/_next/-/commons.js:25486:19)
at http://localhost:3000/_next/-/commons.js:25513:19
at Array.forEach (native)
at http://localhost:3000/_next/-/commons.js:25511:29
at Form.validateIfNeeded (http://localhost:3000/_next/-/commons.js:26490:213)
at Form.componentWillReceiveProps (http://localhost:3000/_next/-/commons.js:26558:18)
at http://localhost:3000/_next/-/main.js:19132:23
at measureLifeCyclePerf (http://localhost:3000/_next/-/main.js:18596:12)
at ReactCompositeComponentWrapper.updateComponent (http://localhost:3000/_next/-/main.js:19131:9)**
If I remove the validate prop. the page renders as expected.
Issue Analytics
- State:
- Created 7 years ago
- Comments:5
Top Results From Across the Web
Field Level Validation Validator is not a function #2515 - GitHub
Hi, I have a simple signup form component and Im trying to use field level validation on each field. Everytime I pass validate...
Read more >redux-form field validation level does not accept functions in ...
1 Answer 1 ... Yes, basically you need to create the validation function outside of your render() method because every time the form...
Read more >Validation - Formik
Form-level validation is useful because you have complete access to all of your form's values and props whenever the function runs, so you...
Read more >Validate - Go Packages
Package validator implements value validations for structs and individual fields based on tags.
Read more >Field-Level Validation Example - Redux Form
If the value is invalid, the validation function should return an error. This is usually a string, but it does not have to...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
I’m getting the same error @khpatel4991 could you share the details of your error so maybe it can help me fix the error
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.