Basically I want to be able to write the following:
html! {
<div>
<Custom />
</div>
}
I guess I just need to add a : after the component. This is a little strange, but after reading the macro's impl I get why it's this why for the moment.
Also, not directly related, but it was causing me weird error messages. I find that needing a trailing comma shouldn't be needed, for example:
html! {
<div class="container"></div>
}
@nixpulvis You are right, macro is little strange, because we should use rules to separate identifiers and Types. I think we can improve it later with a compiler plugin (like https://github.com/tomjakubowski/json_macros do), but while it's a nightly feature.
Fixed in 0.7
Most helpful comment
@nixpulvis You are right, macro is little strange, because we should use rules to separate
identifiersandTypes. I think we can improve it later with a compiler plugin (like https://github.com/tomjakubowski/json_macros do), but while it's a nightly feature.