I'm trying to add custom theme using twind, Is there any way to use css variables with https://twind.dev/?
Asked
Active
Viewed 441 times
1 Answers
0
You could follow this one: https://twind.dev/handbook/configuration.html#theme
And rather than
gray: colors.trueGray
you could use a CSS variable
gray: 'var(--color-bluegray-300)'
Thanks to the variable from an upper scope.

kissu
- 40,416
- 14
- 65
- 133
-
It's not working. I've done this with tailwindcss before but the issue is twind is not recognizing extended colors somehow. – Mohammadreza May 03 '21 at 15:25
-
Maybe they do not have any `extend` and you should rely on writing all the colors by yourself. – kissu May 03 '21 at 15:27