snabbdom-pragma
snabbdom-pragma copied to clipboard
Is `h('div#id.class1.class2', ...)` needed ?
ATM, the sel property in Snabbdom-pragma is only related to the html element.
Snabbdom-JSX use something like the following code, to handle something they call Id and static classes (sel attribute)
<div selector="#id.class1.class2" />
Today, you can use the following code to achieve this
<div id="id" class={{ 'class1': true, 'class2': true }} />
So, Is this feature requested ?
The following code is also working as intended
<div id="id" attrs-class="class1 class2" />
We can also aim to use
<div id="id" class={['class1', 'class2']} />
https://github.com/JedWatson/classnames