4 ms·
<Icon is="Icon" /> <span is="span" /> <CodeSmell is="Stinky" /> Besides, you kinda lose all the advantages of using javascript to style, which is complex com
by danr4 11y ago
<Icon is="Icon" />
<span is="span" />
<CodeSmell is="Stinky" />
Besides, you kinda lose all the advantages of using javascript to style, which is complex computations and co.
- clessg 11y ago<div is="dialog"> <h1 is="title"> { this.props.title } </h1> <div is="actions"> <Button is="Cancel" label="Cancel" /> <Button is="Accept" label="Accept" /> </div> </div> Seems more expressive to me than <div className="dialog">. I understand the point though; the example provided on the homepage is very contrived. Few people are going to do something like <span is="span">. (Well, I could be wrong.)
- mateuszf 11y ago> Besides, you kinda lose all the advantages of using javascript to style, which is complex computations and co. No, you dont' loose it. You can still script the "is" attribute, also you can escape to regular className in case of advanced cases. So this is a 80-20 solution.