Replace CSS variables using their real values #1223
Replies: 1 comment 4 replies
-
Some observations I had:
In the above example token('colors.red') returns |
Beta Was this translation helpful? Give feedback.
4 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
I have this problem where the library demands the colors to be passed as hex colour codes and not css variables.
And hence using it through token() does not work. I found
token(colors.primary)
returnsvar(--color-primary)
. And I would like to receive some inputs on how to have the css variables replaced with the original hex values. The end output is expected to bewhen --color-primary: #ff0000 is set on :root. I could not figure out a way to do this, but would appreciate any help.
Beta Was this translation helpful? Give feedback.
All reactions