Tailwind 4 Upgrade tool incorrectly converts classes in "@layer components", into @utilities #16434
Replies: 3 comments 1 reply
-
Hey! This is done on purpose because |
Beta Was this translation helpful? Give feedback.
-
Thanks for getting back to me so quickly :) I guess I'm "surprised", because I've never used the utilities layer. As an example, I used the components layer because I need base styles for
This indicates (to me) that the upgrade tool should only be converting things that were defined in the These aren't things that are using "a CSS feature you'd like to use in your project that Tailwind doesn't include utilities for out of the box" so as far as I can tell, they don't need to be converted to utilities. |
Beta Was this translation helpful? Give feedback.
-
That makes sense - thank you for taking the time to clarify this :) I'm going to manually change these back into components now, but I understand more about why it's like this. If you do get a chance to update the docs, I think that might make sense :) Feel free to close this unless it's useful for people to see |
Beta Was this translation helpful? Give feedback.
-
The upgrade tool from Tailwind 3 to 4 converts classes in my
@layer components
into@utilities
.Stripped down example:
Converted app.css:
Beta Was this translation helpful? Give feedback.
All reactions