-
Notifications
You must be signed in to change notification settings - Fork 194
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
tailwindcss-intellisense is not working #209
Comments
I've just updated my Code. Also reset all the code config folders. The problem still presist.
|
My tailwindcss-intellisense output log is empty but here is my Log (Extension Host) output;
|
Having the same exact problem with nextjs and no logs |
@wadhah101 no it's still unsolved. Do you use NVM? |
No I using node 15 on linux |
update , tailwindcss is giving an output , code repo https://github.com/wadhah101/insat-schedule |
it stopped working for me too like a week ago, don't have any error logs that i can find. |
On my current project, I did some changes in my webpack.mix.js file then I compiled it using "npm run dev" and after that, the IntelliSense stopped working. It works on other laravel projects. Plus, I tried removing the whole tailwind package and install it again but still, it's not working. |
Pulling my hair out here, waiting for a solution :'( |
This kind of worked for me. I see the classes, but can't preview the colors as shown below. I also can't see the little window that has the CSS properties of the class I'm looking at. |
@sanny-io @bradlc what I discovered was that some extensions i had in a dependency had a tailwind.config.js here and that was caugth first by the plugin. @bradlc i am not very familiar with the workflow to run extesions locally to add new features, would it make sense to have a config value to specify the tailwind.config.js file instead of automatically picking the first from that array (https://github.com/tailwindlabs/tailwindcss-intellisense/blob/master/packages/tailwindcss-intellisense/src/class-names/index.js#L41-L53) Maybe show a warning message if multiple files found in that array and tell the user to manually specify the config file. In my case, the first found was not used and yarn install has not been made in that folder, once I deleted it the first file in the following array was the good one and intellisense started to work again. |
@sanny-io But the native HTML files working perfectly, I don't know why as well :'( |
@themustafaomar maybe you also have multiple tailwind.config.js files? |
For me, intellisense is broken when using Create React App, but it works when I use Next.js I followed the official instructions for each as listed here: https://tailwindcss.com/docs/installation Edit: by some miracle, when I went back to the CRA project, intellisense suddenly works. Maybe had something to do with creation of the Next.js project 🤔 |
In my root directory, Nope! But finally, I solved my issue, and it was because of using Wrong way: // tailwind.config.js
import some from './file'
export default {} Right way: // tailwind.config.js
const some = require('./file') // be sure this file using `module.exports` instead of `export default` and not using `import` as well!
module.exports = {} You don't need this anymore and it would be better if forget about it.
|
I can confirm this has stopped working for my NextJS projects as well |
@thiras can I ask what specifically isn't working? Your screenshot indicates that it is working fine, since you have color decorators next to some of your classes ( |
Following this thread because I just install Intellisense in VSCode but the extension doesn't appear to work (I'm using Create React App and followed the installation instructions on the website) |
the extension doesn't work in vscode-darwin-arm64 but work in vscode stable build |
Hi i came to this thread confused also, apparently i installed https://www.npmjs.com/package/postcss and it magically worked. I dont know what it happening but installing the Post-CSS package makes it work (Close the project and reopen it) check out the above images also i dont know if this was a contributing factor but i also went Settings(bottom left corner) > extensions > tailwindcss-intellisense > extension settings. under include languages i did this Hope it helps 👌 |
I've also met this in VS Code 1.53 exploration for Apple Silicon. tailwindcss-intellisense/packages/tailwindcss-intellisense/src/class-names/index.js Line 35 in 84e3bf4
And curiously I've found this For some reason, just changing
Related
NoteIt will resolve a specific case for Apple Silicon, but an original issue that is happening in Linux x64 may not resolve. |
Following is my detailed debug log. I hope this helps to recognize why preventing resolution of the config file. First, let me make clear this case is helpless for multiple configs in a workspace (Check out #218) and user's basic mistake (e.g. lacked Now, tailwindcss-intellisense tries finding out configuration file faster as far as possible, powered by fast-glob module. For efficient work of finding, it internally spawns concurrency threads as many as the number of CPUs. The problem is that getting CPU information is restricted in some environments by various reasons. In Linux, Node.js (libuv) tries to access So an original report of this issue may be caused by not accessible In addition, VS Code exploration for Mac ARM64 (Apple Silicon) is also returning an empty array for some reason: microsoft/vscode#112122. Of course, the result is same in this case. Fortunately fast-glob has patched to deal with this problem. It spawns at minimum 1 process even if detected 0 CPUs (mrmlnc/fast-glob#296). The extension is going to become work correctly by waiting for update of fast-glob and updating dependency. |
Also reporting in that intellisense works on my "business" Intel Macbook Pro but does not work on my "personal" Apple Silicon Macbook Pro |
@bradlc I have been getting a lot of warnings and errors at CSS linting as the screenshot shows. And also I had zero logs under Tools > tailwindcss-intellisense. But somehow that output looks totally fine now despite the warning and errors at CSS linting |
@thiras Please forgive my curious; could you share the result of following steps?
Developer Tools can open from If shown |
Hi @yhatt 🙂 I can confirm this array is empty on my M1 Macbook Air, and I'm using VS Code Exploration build. VS Code Exploration version info:
|
@edwinhollen Thanks! But I'm interesting to this trouble on Linux; the original report of this issue shows occurred in Linux, not Apple Silicon Mac. |
Can you just have a way to force it on? Some of us don't have a single trace of JS or use a CDN or whatever |
How can one manually update this Would love to hear from you soon. |
Going to close this because it's gone totally off-topic 😅 Please open separate issues if you're having problems. To address the original issue @thiras: Those errors come from the built-in VS Code CSS validation. You can disable this by setting the |
@bradlc the issue i mentioned still remains: if multiple tailwind config files are in the same workspace, extension picks the first one which might not be installed and won;t work. |
I would like to add here, that for me to problem apparently was caused by the tailwind.config.js not being tracked by git. (source). |
@filipac Thank you for noting this. I can confirm as I'm currently in the middle of a refactor with two tailwind.config.js files in the workspace. Deleting the old one cleared up the |
I have a problem getting postcss In my project path, there is a file name with '#' 'd:\work\#files\project` Removed the '#' from the file path, everything works. |
I've been trying to get it to work for a while, but it hasn't worked. I've searched for a lot of information, but I saw @sanny-io's suggestion: install HTML CSS Support, and it actually works! This solution worked for me (I don't know why to 👀) The exact same behavior here when working with Vue files, the colors don't show. |
If you are working with nuxt3, you can try this. Add the following configuration to your
detailed: link |
Hello,
I have a tailwind.config.js file on my project root.
Not a single line of log on Output -> tailwindcss-intellisense.
The intellisense is not working even after complete OS reboot.
The text was updated successfully, but these errors were encountered: