Alexander Arbit
01/08/2022, 3:26 AMdiv {
style = {
color = "WHITE"
}
}
but that doesn't work. I've even attempted to grab things like csstype, hoping it was the missing piece, but I just cannot sort out how to make CSS work in this new DSL.Alexander Arbit
01/08/2022, 3:44 AMkotlin-react-css
library
The syntax looks like:
div {
css {
color = Color("#abc123")
}
}
I'm still surprised that it uses css
and not style
for the attribute name, but 🤷Alexander Arbit
01/08/2022, 3:45 AMturansky
01/08/2022, 1:55 PMcss
- adapter for className
configuration (it’s common practice in JS world)
2. style
- existed HTML tag
div {
style {
+ "color: red"
}
}
3. For inline style you can use
div {
style = jso {
color = Color("#abc123")
}
}
turansky
01/08/2022, 4:34 PMdiv {
style = jso {
color = NamedColor.white
}
}