Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Preact type definitions + potentially other frameworks #5

Open
itsMapleLeaf opened this issue Mar 13, 2021 · 1 comment
Open

Preact type definitions + potentially other frameworks #5

itsMapleLeaf opened this issue Mar 13, 2021 · 1 comment
Labels
enhancement New feature or request help wanted Extra attention is needed

Comments

@itsMapleLeaf
Copy link
Contributor

As of writing, only definitions are included for React. As a framework-agnostic solution, should probably add broader support.

Not sure if there are any others we should include as well, like Inferno, or Vue JSX? I feel like the usage numbers aren't high enough to justify this; gotta draw the line somewhere. But if someone contributes them, I won't say no 🤷‍♂️

@itsMapleLeaf itsMapleLeaf added enhancement New feature or request help wanted Extra attention is needed labels Mar 13, 2021
@sastan
Copy link
Contributor

sastan commented Mar 13, 2021

Typescript uses the JSX namespace that is usually provided by those libraries. Maybe have an internal minimal JSX namespace type which would only support the additional props.

Like here (https://github.com/tw-in-js/use-twind-with/blob/main/packages/preact/index.ts#L17) but using the JSX namespace.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request help wanted Extra attention is needed
Projects
None yet
Development

No branches or pull requests

2 participants