Replies: 1 comment 6 replies
-
Hey there! Yeah CSS variables don't work inside strings in CSS, there is in fact no way to construct strings at runtime at all so what you're trying to build can't really be done in CSS only right now I'm afraid. There's open discussion about a feature like this in the csswg-drafts issues. I do agree though that this might be useful to add to the I recommend for now that you use the JavaScript plugin API to get the behavior you want. |
Beta Was this translation helpful? Give feedback.
6 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
What version of Tailwind CSS are you using?
v4.0.17
Reproduction URL
https://play.tailwindcss.com/zRMgL8AdRl?file=css
Describe your issue
These two plugins that worked for Tailwind CSS 3, they no longer work for in version 4 of Tailwind CSS. Because it seems like CSS variables don't work inside
url("")
.https://www.npmjs.com/package/tailwind-heropatterns
https://www.npmjs.com/package/tailwindcss-hero-patterns
There may be other scenarios like this that I'm not aware of.
So, without this issue being resolved, creating custom plugins like mentioned above, won't be possible in Tailwind CSS 4.
Beta Was this translation helpful? Give feedback.
All reactions