galki / material-ui-form

State and validation support for Material-UI form components
MIT License
11 stars 3 forks source link

add custom validators #40

Open galki opened 6 years ago

galki commented 6 years ago
voletiswaroop commented 6 years ago

We can achieve isMinLength & isMaxLenght by using following code: Ex 1: let length = [{ isLength: { min: 2, max: 50 } }]; data-validators="isLength"

Ex 2: inputProps={{minLength: 1, maxLength: 10}}