Hi, how to add simple inline style attribute with ...
# react
r
Hi, how to add simple inline style attribute with kotlin-react? I don't want to generate css classes like it is done with
kotlin-styled
.
I've tried different combinations of
attrs.style
and
attrs.jsStyle
found in different examples, but all I get is ClassCastException or other strange errors.
This worked:
attrs["style"] = js { backgroundColor = "red" }
🎉 1
👍 1