<select
name="destination"
className="form-control"
onChange={ this.handleDestination }>
<option value=""> - { translations.destination_town } -</option>
{
destinationTowns.map( (town, index) => {
return <option key={ index } value={ town.id }>{ town.name }</option>
})
}
如何验证此选择框,例如,如果用户未选择任何选项,则传递错误消息,表明该字段是必需的?