So I'm trying to read the value of something that triggered the event, in my case its Select tag but when I change the tag its giving me an error saying TypeError: Cannot read property 'target' of undefined. I think it means event or target in undefined, My code is like this
function RandomScreen() {
function handleChange(event) {
ChangeSomeOtherState(event.target.value)
}
return (
<select onChange={() => handleChange()}>
{StateWhichIsArray.map(String => {
return (
<option value={String} key={String} >{String}</option>
)
})}
</select>
)
}