Skip to content

How to get the conflicting classes? #384

Answered by dcastil
akinuri asked this question in Help
Discussion options

You must be logged in to vote

Hey @akinuri! 👋

This is an interesting use case, but also very custom. At the moment, your workaround is indeed the only way to get the removed classes. I use the same approach to mark the removed classes with a red background in https://codesandbox.io/p/sandbox/tailwind-merge-playground-cssr35?file=%2Fsrc%2Findex.ts.

I think it makes sense for tailwind-merge to expose a low-level API to get that info. This will take some time because I'm not sure yet about the best way to provide it, but I created the issue #385 to track that specific feature and collect some input.

In case you need a good solution for this faster, you can fork tailwind-merge and modify it to get this functionality. All …

Replies: 1 comment 2 replies

Comment options

You must be logged in to vote
2 replies
@akinuri
Comment options

@dcastil
Comment options

Answer selected by akinuri
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Help
Labels
context-v2 Related to tailwind-merge v2
2 participants