-
Notifications
You must be signed in to change notification settings - Fork 27
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
feat(mox): add inline method call syntax #277
base: main
Are you sure you want to change the base?
Conversation
@anp would love some 👀 and feedback whenever you have some time 😊 |
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.
This looks great to me! Sorry for the delay in reviewing, getting vaccinated put a big dent in my open source free time 😅 .
Aside from the doc nit this seems fine to land. Can you run cargo ofl versions
to bump the patch version for mox and add an entry to its CHANGELOG.md
? That way it will release to crates.io on merge.
/// To allow calling methods with 0 or more than 1 arguments, | ||
/// an inline method call syntax is available | ||
/// | ||
/// e.g. `<foo {bar()} {baz(123)} />` expands to `foo().bar().baz(123).build()` |
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.
Can the 123 example have 2 args to motivate usage?
closes #276
MoxBlock
- intermediate representation of a "syn-rsx block that needs to be transformed", was an artifact of my tooling around that I left in to easily support more transformations in the futureMoxAttr
- now an enum representing the three kinds of attributes supported:<foo bar=123 baz {bingus()}>
->foo().bar(123).baz(baz).bingus().build()