-
-
Notifications
You must be signed in to change notification settings - Fork 8.9k
Open
Labels
✨ feature requestNew feature or requestNew feature or requesthas workaroundA workaround has been found to avoid the problemA workaround has been found to avoid the problemscope: types
Description
What problem does this feature solve?
Currently the JSX types specify that native input event handlers receive an Event
: https://github.com/vuejs/vue-next/blob/8ed3ed6c27b0fb9a1b6994eddc967e42d4b3d4e1/packages/runtime-dom/types/jsx.d.ts#L1210
This is very general compared to the runtime type. As an example, @input
on an input element will actually give you an InputEvent
. It would be useful if the correct event type could be inferred so that we don't have to cast the event object. I assume it's not as simple as e.g. replacing Event
with InputEvent
for onInput
or it would probably have been done already, but is this something that could potentially be solved?
What does the proposed API look like?
N/A, just a type improvement, not an API
ctrlplusb, rafasoares, kidonng, tajespasarela, extrem7 and 1 more
Metadata
Metadata
Assignees
Labels
✨ feature requestNew feature or requestNew feature or requesthas workaroundA workaround has been found to avoid the problemA workaround has been found to avoid the problemscope: types