-
-
Notifications
You must be signed in to change notification settings - Fork 1.4k
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
Generic functional components #1756
Generic functional components #1756
Conversation
Visit the preview URL for this PR (updated for commit 014ccec): https://yew-rs--pr1756-lukechu10-function-c-snu53uqz.web.app (expires Tue, 02 Mar 2021 23:13:12 GMT) 🔥 via Firebase Hosting GitHub Action 🌎 |
Is this still a draft? There are a lot of TODO comments left. Btw, please update your "pass" tests such that they bring as few members as possible into scope. This helps ensure that the macro code is (and more importantly stays) hygienic. |
Yeah, I'll try to improve the error messages some more as well as the pass test :) |
I also want to try this out with const generics |
Ok, const generics seem to be working. I can't enable it in the CI tests because it is not in stable yet. |
Everything seems to be working now :) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The implementation looks solid 👍
packages/yew-functional-macro/tests/function_attr/generic-lifetime-fail.rs
Outdated
Show resolved
Hide resolved
packages/yew-functional-macro/tests/function_attr/generic-props-fail.rs
Outdated
Show resolved
Hide resolved
Co-authored-by: Simon <[email protected]>
Co-authored-by: Simon <[email protected]>
Co-authored-by: Simon <[email protected]>
Description
Implements parsing and expansion for generic
#[function_component]
components.Fixes #1739
Checklist
cargo make pr-flow