Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR CSHARP

Customize yup number

const schema = yup.object().shape({
  name: yup.string()
    .required('name is required'),
  age: yup.number()
    .typeError('age must be a number')
    .positive('age must be greater than zero')
    .required('age is required')
});
Source by github.com #
 
PREVIOUS NEXT
Tagged: #Customize #yup #number
ADD COMMENT
Topic
Name
8+3 =