Concept
React wraps DOM events in typed synthetic events: React.ChangeEvent<HTMLInputElement>, React.FormEvent and so on. The generic parameter is the element the handler is attached to.
The tutor works through these with you, in conversation and code. A session ends when you have shown them, not when a video does.
A few lines that show Typing events doing its job.
function Search({ onSearch }: { onSearch: (q: string) => void }) {
const [query, setQuery] = useState("");
const handleChange = (event: React.ChangeEvent<HTMLInputElement>) => {
setQuery(event.target.value);
};
const handleSubmit = (event: React.FormEvent<HTMLFormElement>) => {
event.preventDefault();
onSearch(query.trim());
};
return <form onSubmit={handleSubmit}><input value={query} onChange={handleChange} /></form>;
}Typing the event as React.ChangeEvent<HTMLElement>. The generic element has no value property, so event.target.value is an error; name the exact element.
Your roadmap puts these before Typing events, unless you already know them.
Once a session shows you understand Typing events, it comes back for review. Each review takes a minute and tells the memory model how well you still know it.