Last active
July 6, 2021 16:43
-
-
Save filipemacedo/e90e9aa952f118c2ba083d5cfd763796 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Yup.object({ | |
password: Yup.string().required('Password is required'), | |
passwordConfirmation: Yup.string() | |
.required('Confirmation is required') | |
.test('match', 'Passwords must match', function(value) { | |
return this.parent.password === value | |
}) | |
}) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment