Replies: 4 comments 5 replies
-
I'd love to hear the official stance on this. Even a general or vague answer would help give some insight into how both Tailwind and tailwind-merge might evolve. |
Beta Was this translation helpful? Give feedback.
-
Having a native helper function for class merging would be huge |
Beta Was this translation helpful? Give feedback.
-
Now that there's a Vite plugin, I believe they could automatically insert a merge function in all places where classes are specified, e.g.:
And, with awareness of what classes exactly are used in the codebase, this EDIT: basically the same idea as described here: dcastil/tailwind-merge#413 (comment) |
Beta Was this translation helpful? Give feedback.
-
I think a lot of the problems tailwind merge solves can also be solved by having styling split between the component and utility layers. However its very common to use tailwind for at least property modifiers, but also for base component styling by tools like shadcn. I wonder if tailwind could just have a configurable prefix to use a class on the component layer. So You could also have this plug into a variant, but the idea only works if you duplicate the classes for the differing specificity. |
Beta Was this translation helpful? Give feedback.
-
I am really looking forward to Tailwind v4. I plan to start experimenting with it soon.
I'm here today to ask if there's anything that can be done to facilitate the transition to third-party modules like tailwind-merge (dcastil/tailwind-merge#468).
This library is super useful for component libraries and overrides.
To give you more context:
Thank you for your time and your work!
Beta Was this translation helpful? Give feedback.
All reactions