Procedural validation?
See original GitHub issueis there a way to prevent the next validation from firing if the one before fails?
Example I see that my axios request fires even though .email fails.
is this because Axios returns a promise and because of that I loose the ability to have procedural validation?
validationSchema: object().shape({
email: string()
.email('Invalid email address')
.required('Email is required!')
.test('email', 'this email is already taken', value => {
return new Promise((resolve, _reject) => {
Axios.get(make_url('/users/precheck?user[email]=' + value)).then(
reponse => {
resolve(reponse.data.precheck == 'ok');
},
);
});
}),
}),
Issue Analytics
- State:
- Created 5 years ago
- Reactions:1
- Comments:5 (2 by maintainers)
Top Results From Across the Web
Perform Procedural Validation - TechDocs - Broadcom Inc.
Procedural validation provides the program with complete control over which data is validated, and the order in which the validation is ...
Read more >Procedure for Method Validation (20180101)
This is the metrology laboratory policy and procedure for developing and validating test or calibration methods when no international or national procedures are ......
Read more >Method Validation Procedure
Method validation seeks to quantify the likely accuracy of results. Page 5. STANDARD OPERATING PROCEDURE. Q-Pulse Reference: Method Validation Procedure.doc.
Read more >Process Validation Procedure - Medical Device Academy
Process validation is required whenever there is a process that affects product quality that cannot be 100% inspected or where inspection/testing of the...
Read more >Process Validation: General Principles and Practices - FDA
A. General Considerations for Process Validation . ... documented, and approved in accordance with the established procedure appropriate for.
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 open to adding something. I’m not sure what the API would look like tho. I’d take a PR tho for a good proposal
To be honest it sounds like it would be a lot of rewriting stuff. If you think its a good idea (and I wholly support this) maybe a feature ticket would be in order to get more input from other users?