In React, onChange
in the following code is regarded as an on input
event handler, not on change
, if I understand correctly:
<input onChange={() => ()}></input>
But I do want to handle on change
events. How do I do that?
Updates:
In React, onChange
will be triggered on input events, so it cannot handle on-change events (for HTMLInputElement
).
I want to handle on-change events, not on-input events.