-
Notifications
You must be signed in to change notification settings - Fork 211
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
Suggestions for Tailwind CSS v4 are not provided when using the Standalone CLI #1145
Comments
Yes it would be nice to activate it without requiring the now optional |
It does not. In a bare bones project it'll activate just fine with v4 without a config file. If it's not activating that's a bug. Mind opening your project and posting the output from "Tailwind CSS: Show Output"? |
I also am required to add an empty tailwind.config.js in order to get this to work within nvim. |
@thecrypticace Here it is, using in a
|
Oooooh okay. You're using the Standalone CLI with Rails and the bundled Tailwind CSS version in IntelliSense is still v3.4. I'll have to come up with a solution to bundle both and pick the right one when its not installed via npm. As a short term workaround you can |
@thecrypticace got it! I have it posted here too for reference: rails/tailwindcss-rails#450 (comment) |
@danwetherald @dlongz Are you both also using rails? |
Came looking for this, had the same problem.. Installed vite with react... intellisense didn't work until I added the optional tailwind.config.js (and it's blank) |
@cb911nr Did you create a CSS file that imports If you did and it still didn't pick it up mind opening a separate issue with the steps you took? |
So i was able to get it to work by including a basic tailwind.config file. I didnt need to add any experimental flags or point it to the config file. While trying to get the output from Tailwind CSS i deleted the tailwind.config file. But after deleting it the intellisense still work. I'll creat a new project without the tailwind.config to replicate the bug and post the output from that project. |
No not rails. Just react19 via vite. |
Vite as well here. |
Here is the output form Tailwindcss IntelliSense [Info - 9:43:29 PM] [GLOBAL] No matching project for document { Steps Taken to create new project
|
@dlongz Can you give me all of the output from when you do that. Not just the last message? |
Well, Yes I can however now its working in the same project i created to reproduce the bug. I didn't realized i should copy everything before. it had the same output back to back for some time just different timestamps. So i just copied the last one since I didn't see any difference. I also didn't scroll all the way to the beginning, it was really long. Here is the output anyways but on this one it is working and it does not have the tailwind.config file. Locating server… |
Ah yeah if it's working I don't think the output is going to help me much. Need to see what's happening when it isn't. But, good to know it's working for you now 👍 |
So i created a new project github2-tailwindcss-bug Here is the outpu from Tailwind Intelisense:
|
Well I spoke too soon. lol. Not working. Interested to see what made the known non-working project to suddenly work. |
Ah so it looks like you opened |
Ok i'll make a new project outside of the React-Refresher directory and let you know how it turns out. |
Im running into the same issue. The intellisense only works when im in the package/ui folder files, but as soon as i try to import package/ui from any other app inside of my monorepo, the intellisense stops working again. :/ |
@ericmesmo Could you open a separate issue with a reproduction? |
@thecrypticace I'll still post the output just in case you can spot a pattern for why it wasn't activating before. Locating server… |
Same here. I am doing this in a go project with the tailwind cli so doing Maybe we can pass in configuration to tailwind LSP for a filepattern to determine if tailwind LSP should be active instead of defaulting to |
I merged a fix for the standalone CLI stuff in #1157. Gonna push out a release (probably tomorrow at this point) that enables IntelliSense for v4 even when not using npm. The drawback is that right now things like |
What if I am only using the tailwind cli? Do I still need to have a |
What version of VS Code are you using?
Version: 1.96.4 (Universal)
Commit: cd4ee3b1c348a13bafd8f9ad8060705f6d4b9cba
Date: 2025-01-16T00:16:19.038Z
Electron: 32.2.6
ElectronBuildId: 10629634
Chromium: 128.0.6613.186
Node.js: 20.18.1
V8: 12.8.374.38-electron.0
OS: Darwin arm64 23.6.0
What version of Tailwind CSS IntelliSense are you using?
0.14.1
What version of Tailwind CSS are you using?
"tailwindcss": "^4.0.0"
What package manager are you using?
npm
What operating system are you using?
macOS
Tailwind config
None as per Tailwind 4
index.css
@import "tailwindcss";
VS Code settings
Reproduction URL
n/a
Describe your issue
Tailwindcss Intelisense still needs a tailwind.config.js file however Tailwind 4 doesn't recommend using one in favor of the '''@import "tailwindcss";''' in the CSS file. With current recommended configuration, IntelliSense doesn't work at all.
The text was updated successfully, but these errors were encountered: