Using exclusively XML? From now on, you can import elemi.xml
and elem
will then default to elemX
behavior.
- For old behavior, use
import elemi
orimport elemi.html
.
Now there's a new, faster and prettier syntax for adding attributes at runtime:
elem!"div"(
attr("id") = "named",
attr("class") = ["hello", "world!"],
)
// <div id="named" class="hello world">