Is there something in Material 3, to combine Mater...
# compose
y
Is there something in Material 3, to combine Material Extensions with Dark mode. In Material 2, it was like this:
Copy code
val ColorScheme.link: Color
    get() = if(isLight) colorX else colorY
But, this doesn’t work with M3?
l
There isn't, and this approach in general is dangerous and fragile - instead it's better to explicitly provide your own values in a CompositionLocal so it can be defined in the same place as the color scheme, and better kept up to date