vue-tsx-support
vue-tsx-support copied to clipboard
Enhance types of standard HTML attributes using Type Literals (ex: input "type")
None of the DOM types exposed by /types/dom.d.ts
are using the Type Literals feature - and it would work great I think.
Example: this is the current declaration for the "type" attribute on the "input" interface:
type?: string;
A more accurate type definition would be:
type?: 'text' | 'button' | 'submit'; // other literals are omitted for brevity
this will allow intellisense to suggest possible values for type
.
same if true for other attributes