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

Schema listed for Preact no longer valid. #26

Open
kalebo opened this issue Feb 17, 2022 · 0 comments
Open

Schema listed for Preact no longer valid. #26

kalebo opened this issue Feb 17, 2022 · 0 comments

Comments

@kalebo
Copy link

kalebo commented Feb 17, 2022

JFYI The shape of vdom nodes has changed in Preact. See the following definition from their src/index.d.ts:

interface VNode<P = {}> {
	type: ComponentType<P> | string;
	props: P & { children: ComponentChildren };
	. . .
}

For the size of this library though, it's easier just to vendor it directly into what ever project you want and add explicit call to Preact.createElement for the recursive base case. A similar fix for would make it work with React.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant