Replies: 1 comment
-
The way Simple React Validator works is that it just validates data. So if for example you are just requiring a radio button to have a selected value, and you start storing the value of what gets selected in state then you would just do something like: <input type="radio" name="size" value="small" checked={this.state.size === 'small'} onChange={this.updateState}> Small
<input type="radio" name="size" value="medium" checked={this.state.size === 'medium'} onChange={this.updateState}> Medium
<input type="radio" name="size" value="large" checked={this.state.size === 'large'} onChange={this.updateState}> Large
{this.validator.message('size', this.state.size, 'required')} So when |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Hi I have radio button as input. But their no example of radio button validation
Beta Was this translation helpful? Give feedback.
All reactions