I am having a input in react component, When the input is inside , Enter button will trigger a click, but if input is not wrapped inside form, Enter does not work,
Is wrapping input by form the only way to activate Enter button ?
<div>
<input name=“name” type="text"
value={somevalue} onChange={this.handleChange}/>
<button id=“searchbutton”
onClick={this.handleSubmit}>
{search label}
</button>
</div>