Please see this minimum example below:
/** @jsx h */
import { h, FunctionalComponent } from 'preact';
const Test: FunctionalComponent = () => {
return (
<select
value="1"
onChange={(event) => {
console.log(event.target.value);
}}
>
<option value="1">1</option>
<option value="2">2</option>
</select>
);
};
How do I resolve the error where it says Object is possibly 'null'?
