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 V4 support #1328

Open
Bricklou opened this issue Jan 23, 2025 · 8 comments
Open

Tailwind V4 support #1328

Bricklou opened this issue Jan 23, 2025 · 8 comments
Labels
enhancement New feature or request

Comments

@Bricklou
Copy link

Is your feature related to a problem?

Tailwindcss V4 dropped few hours ago. And with the new major release, the way configuration are handled completely, moving from a js file to a css-firsr configuration. Which means the tailwindcss pack doesn't work anymore since it doesn't detect any JS configuration.

Describe the new feature

The tailwindcss pack needs some tweaking in order to make it work again.

Additional context

No response

@Bricklou Bricklou added the enhancement New feature or request label Jan 23, 2025
@azdanov
Copy link
Contributor

azdanov commented Jan 31, 2025

Easiest fix would be to add tailwind.css to the rooter config file list and update the readme in the pack to mention that. I guess. Haven't tried yet.

@Bricklou
Copy link
Author

The issue is that it enforces the file name. So, it won't work on existing projects that don't use this name.

@azdanov
Copy link
Contributor

azdanov commented Jan 31, 2025

No, it won't, but an alternative is to always scan all CSS files for the magic string, which will worsen performance. There's kind of no easy solution here thanks to their decision to drop a config file.

@Bricklou
Copy link
Author

Bricklou commented Jan 31, 2025

@azdanov
Copy link
Contributor

azdanov commented Jan 31, 2025

Yep. I've seen that.

They seem to have lots of issues themselves with projects not being recognized https://github.com/tailwindlabs/tailwindcss-intellisense/issues

And this could happen in larger projects tailwindlabs/tailwindcss-intellisense#1109

@azdanov
Copy link
Contributor

azdanov commented Jan 31, 2025

Would need some help from someone more experienced in the Neovim and Lua ecosystem 🙂
I just tried a simple solution that helps somewhat with new projects.

@Bricklou
Copy link
Author

Yeah, it looks like it is a big design flaw on their side.

@azdanov
Copy link
Contributor

azdanov commented Jan 31, 2025

Another option is to scan package.json for the tailwind package. But maybe there is a reason they didn't opt in for that.

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

No branches or pull requests

2 participants