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

Document absence of special function-like components #15

Closed
Tamschi opened this issue Oct 14, 2020 · 3 comments
Closed

Document absence of special function-like components #15

Tamschi opened this issue Oct 14, 2020 · 3 comments
Labels
accepted This will be worked on good first issue Good for newcomers type: documentation Related to documentation and information. type: feature Brand new functionality, features, pages, workflows, endpoints, etc.
Milestone

Comments

@Tamschi
Copy link
Owner

Tamschi commented Oct 14, 2020

Asteracea component syntax is quite concise and Rust erases zero-sized instances at compile time. Add such, components without instance fields will behave in a function-like way.

Additionally, it is possible to return a Node created by a fragment! invocation from a plain Rust function, and to use this function in Rust expressions in other Asteracea macro calls.

The documentation should include an assert that the instance size actually is 0.

@Tamschi Tamschi added type: feature Brand new functionality, features, pages, workflows, endpoints, etc. type: documentation Related to documentation and information. accepted This will be worked on good first issue Good for newcomers labels Oct 14, 2020
@Tamschi Tamschi added this to the v0.1.0 milestone Oct 14, 2020
@Tamschi
Copy link
Owner Author

Tamschi commented Oct 14, 2020

This issue is part of #16.

@Tamschi
Copy link
Owner Author

Tamschi commented Dec 1, 2020

The relevant assert has been implemented as test in fb04d72, but it would be good to show off a component that prints its own size to that end.

@Tamschi
Copy link
Owner Author

Tamschi commented Dec 2, 2020

@Tamschi Tamschi closed this as completed Dec 2, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
accepted This will be worked on good first issue Good for newcomers type: documentation Related to documentation and information. type: feature Brand new functionality, features, pages, workflows, endpoints, etc.
Projects
None yet
Development

No branches or pull requests

1 participant