I currently have a custom Vue component library which uses tailwindcss. To avoid naming collisions with other libs I currently use a custom tailwind prefix.
If I want to use a tailwind UI component I always have to add my prefix manually for all the tailwind classes (so I can't simple copy and paste the code).
So I'm wondering: What's the best strategy to deal with such naming collisions? Is there a way to prefix tailwind classes during build time, to avoid adding prefixes manually all the time?
What if you're using Tailwind and another library that also uses a common class, like .my-4 (Bootstrap, for example).
If you don't prefix before building, how would the build system know what class to prefix?
You could use a tool like VS Code Intellisense to prefix it for you while you develop https://github.com/bradlc/vscode-tailwindcss/issues/104
We're going to fix this at the Tailwind UI level by making it possible to add a prefix to the code snippets 馃憤 No plans for a template processing thing built into Tailwind though I'm afraid.
Most helpful comment
We're going to fix this at the Tailwind UI level by making it possible to add a prefix to the code snippets 馃憤 No plans for a template processing thing built into Tailwind though I'm afraid.