Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

tailwind config prefix duplicates dashes in CSS class names #14

Closed
alesso-x opened this issue Oct 14, 2020 · 1 comment
Closed

tailwind config prefix duplicates dashes in CSS class names #14

alesso-x opened this issue Oct 14, 2020 · 1 comment

Comments

@alesso-x
Copy link

Using the prefix from the tailwind docs tw- produces classes with extra dashes. Instead of tw-bg-black, it becomes tw--bg-black.
Screen Shot 2020-10-13 at 10 40 40 PM

I think the fix is to just check if the prefix ends with a dash and trim it here.

@rogden rogden closed this as completed in db5f4ca Oct 14, 2020
@rogden
Copy link
Owner

rogden commented Oct 14, 2020

@alesso-x Thanks for reporting! Given the prefix can contain any valid CSS selector character, I ended up concatenating the prefix directly with the Tailwind class name without any additional logic to add/strip/replace characters.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants