Skip to content
This repository was archived by the owner on Dec 15, 2022. It is now read-only.

Conversation

@aminya
Copy link
Contributor

@aminya aminya commented Sep 27, 2020

This adds type definitions for etch.

@aminya
Copy link
Contributor Author

aminya commented Sep 27, 2020

@lierdakil Could you take a look at this?

export function dom<T extends keyof HTMLElementTagNameMap>(tag: T, props?: HTMLElementTagNameMap[T] & EtchExtraProps & Props, ...children: ChildSpec[]): EtchJSXElement
export function dom<T extends keyof SVGElementTagNameMap>(tag: T, props?: SVGElementTagNameMap[T] & EtchExtraProps & Props, ...children: ChildSpec[]): EtchJSXElement
export function dom<T extends JSX.ElementClass>( tag: ElementClassConstructor<T>, props: T["props"],...children: ChildSpec[]): EtchJSXElement
export function dom(tag: string, props?: EtchExtraProps & Props, ...children: ChildSpec[]): EtchJSXElement
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

dom.tags are missing. I need to write a script to generate those instead of writing them by hand.

@aminya aminya mentioned this pull request Jan 7, 2021
3 tasks
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant