-
Notifications
You must be signed in to change notification settings - Fork 219
Autocomplete not working in apps directory with Tailwind v4 and plugin version 0.14.17 on Next.js Turborepo #1377
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
Comments
Can you test 0.14.18 and see if your issue is fixed? |
|
|
Same error occurred and I also fixed by downgrade to 0.14.16 from 0.14.19. In my case also same, works for ui/ (library) which located in same depth with www/ (nextjs) below is output when try to autocomplete
|
I was seeing the same or similar issue and found #1033 by searching for the error |
Unfortunately, I am using Tailwind with Zed editor which doesn't support downgrading the version of LSPs. I can share that my logs find zero projects to initialize with on startup:
Not sure if that deprecation warning is related, but I would assume not (since it's just a warning and not an error). But then I get this output for every file I open:
In the LSP info, I see that the
Mine actually does not work anywhere in the repository, so not sure what the difference is in my case. |
I also met, can only work in 0.12.18 |
Nah, it's not. I need to make a PR to Zed to change how they pass that stuff through by default but just have not done that yet.
This tells me that it can't find any Tailwind CSS configs in your project. Could you share a reproduction? It would be super helpful to figure out what you're expecting to work and why the server can't find anything.
You can! (sorta). I use Zed every day with a local build of the server. If you install the language server yourself globally (or really just in any folder somewhere) you can specify a custom language server path in your settings:
The relevant NPM package is @David2k13 Can you please provide a reproduction and logs (if in VSCode "Tailwind CSS: Show Output") |
I can try to put together a minimal reproduction tomorrow, but for now: my setup was pretty much just using From what I saw in the LSP ReadMe and the relevant source code, for Tailwind 4 it just needs a It did previously work a few weeks back with Zed, so something definitely changed.
Might give this a try tomorrow, too, and see if v0.14.16 works as expected. |
solve with version |
Me too, created through "create-next-app", using tailwind 4 and tailwind plugin 0.14.19, auto completion plugin does not work. |
Works in |
@bohdan-basov @stempest0925 Can either of you provide a reproduction repo I can clone, system information, VSCode settings, etc…? I'd really like to help solve whatever these problems are you're having but I can't without having actionable information. I test these processes all the time and don't generally encounter problems. |
Here's a repro: https://github.com/0-CAT/zed-1377-repro As additional information: I first tried creating a repro using So, I deleted that and re-created using PNPM as the selected package manager, and that does not work: Thinking that maybe something changed recently that doesn't play nicely with the symlinks that PNPM uses? |
|
Thank you. I created multiple versions of next projects and changed multiple versions of intellisense. I found that the problem was the compatibility between tailwind 4 and sass. As long as I created a .scss file, I would lose the syntax prompt regardless of whether it was imported or used. However, this is unstable.
I am used to using sass in the next project. After reading the documents of next and tailwindcss, I found this sentence "Think of Tailwind CSS itself as your preprocessor — you shouldn't use Tailwind with Sass for the same reason you wouldn't use Sass with Stylus." Is this the design of the plug-in itself?
|
@0-CAT A few things:
Is that perhaps the difference between the screenshots you showed? Because when I clone the project NPM and PNPM correctly show "no matching project for document" and then after things are edited (and the server restarted because of the bug) they both work. |
Fix for the language server bug here: #1387 |
Works in 0.14.16 for me. Using pnpm monorepo setup with Tailwind 4 and vite |
Thanks for noticing that I missed the import. It looks like I just forgot to commit the change before I pushed. I'm wondering if maybe my testing was thrown off by that bug, since it's not likely that I restarted the LSP every time I added an import or moved files around. When I get back in front of my laptop tonight, I'll take a look again using 0.14.19 and see what's up. I definitely got it working with 0.14.16 last night but will take another pass with 0.14.19. |
@0-CAT I'll be pushing out an update tomorrow to fix that bug btw so maybe wait for 0.14.20 and hopefully things will be fixed for you. |
@thecrypticace Thanks! I've picked up v0.14.20 and given it a spin. I'm seeing projects get initialized and the auto-complete is looking good when working on components the However, with my Do you know if something has changed that would affect this, and is this the expected behavior? |
I've seen this issue in a monorepo with multiple SvelteKit based projects. The ones where it works have an |
I'm experiencing this with 0.14.21 and tailwindcss v4 in Turborepo. |
downgraded to 0.14.16 and it starts working for me. |
Add workaround.css to import globals.css and fix Tailwind CSS IntelliSense not working in workflow-designer-ui package. Related to: tailwindlabs/tailwindcss-intellisense#1377
What version of VS Code are you using?
v1.100.2
What version of Tailwind CSS IntelliSense are you using?
For example: v0.14.17
What version of Tailwind CSS are you using?
v4.0.8
What package manager are you using?
pnpm
What operating system are you using?
macOS
Tailwind config
VS Code settings
Reproduction URL
A public GitHub repo that includes a minimal reproduction of the bug. Please do not link to your actual project, what we need instead is a minimal reproduction in a fresh project without any unnecessary code. This means it doesn't matter if your real project is private/confidential, since we want a link to a separate, isolated reproduction anyways.
Describe your issue
I am using Tailwind CSS v4 on a Next.js Turborepo project. Autocomplete only works in my
packages/ui
directory but does not work in myapps
directory. After further investigation, I discovered that this bug was introduced in the latest plugin version: 0.14.17. Autocomplete works as expected with version 0.14.16.Steps to Reproduce
packages/ui
but not inapps
.Expected Behavior
Autocomplete should work in both
packages/ui
andapps
directories regardless of the plugin version.Actual Behavior
Autocomplete only works in
packages/ui
when using plugin version 0.14.17. It does not work inapps
.Additional Context
Please let me know if more information is needed.
The text was updated successfully, but these errors were encountered: