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

Stateless components #57

Open
aalin opened this issue Feb 2, 2023 · 0 comments
Open

Stateless components #57

aalin opened this issue Feb 2, 2023 · 0 comments

Comments

@aalin
Copy link
Contributor

aalin commented Feb 2, 2023

Components that don't implement any callbacks don't have to be instantiated.

I think there is a type called LambdaComponent that we just need to check for somewhere in lib/mayu/vdom/vtree.rb or maybe we could do it in vnode.rb


Could maybe also not instantiate descriptors for text elements and comments...
Or maybe implement lighter descriptors for them since they don't have props, keys nor children...


It would be good to do #56 first

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