Can CSS variables be used to generate class names?
I am incorporating SCSS in an Angular project and I am looking to base my class names on the
@input color
component property.
I have stored the input in a CSS variable called --color-variable to utilize it in my SCSS file. I am attempting to achieve something like this:
.ps-button--color-#{var(--color-variable)}{}
However, I am encountering a compiler error.
https://i.sstatic.net/dzi9e.png
If you have any suggestions, they would be greatly appreciated.