-
Notifications
You must be signed in to change notification settings - Fork 150
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
Cannot find module 'prettier-plugin-tailwindcss #115
Comments
What package manager are you using? |
What package manager are you using? Yarn |
Super weird, can you provide a reproduction project? |
I swear I didn't change anything but this morning when I come back to work, it is working. |
I thought you heard me when I snuck into your house to fix it last night but I guess not! 🙌 |
I had the same problem, but it was solved after I reload the vscode window. So reload the vscode window might be a solution to this problem. |
I had the same thing happening again couple of days before. Yesterday night finally found something actually helped instead of needing @adamwathan to snuck into my house :). Go to your user settings.json in VSCode and delete the settings coming from prettier extension.
after deleting prettier config related lines mine working setttings.json looked like below; {
"workbench.colorTheme": "Default Dark+",
"editor.tabSize": 2,
"[javascript]": {
"editor.defaultFormatter": "esbenp.prettier-vscode"
},
"git.autofetch": true,
"diffEditor.ignoreTrimWhitespace": false,
"workbench.startupEditor": "none",
"[html]": {
"editor.defaultFormatter": "esbenp.prettier-vscode"
},
"[javascriptreact]": {
"editor.defaultFormatter": "esbenp.prettier-vscode"
},
"tailwindCSS.experimental.configFile": null,
"editor.defaultFormatter": "esbenp.prettier-vscode",
"files.autoSave": "afterDelay",
"editor.codeActionsOnSave": {
}
}
Now everything is working again. It is formatting nicely and sorting classes. I kind of get the inspiration from this stackoverflow post. |
Another update: you might encounter this problem again if you install clsx. (adding this
to setting.json didn't help as the author suggested ) And If you do see,
|
I just did exactly just that and it works xD |
I have this problem when using the GitHub action prettier_action. As I see it, its a fairly simple action. npm install --silent prettier-plugin-tailwindcss
prettier WITH_SOME_VARS Error:
Issue: creyD/prettier_action#111 |
Hey folks! So since we haven't been able to reproduce this ourselves, and since no one has provided a reproduction, and since it sounds like a bunch of you have already figured out workarounds here, I think we're going to close this issue for now. Happy to revisit this if anyone is able to provide a straightforward reproduction 👍 |
What version of
prettier-plugin-tailwindcss
are you using?"prettier-plugin-tailwindcss": "^0.2.1"
What version of Tailwind CSS are you using?
"tailwindcss": "^3.2.4"
What version of Node.js are you using?
v18.13.0
What package manager are you using?
Yarn
What operating system are you using?
Windows
Describe your issue
Although I have installed everything in the correct order and can see the plugin in node_modules folder I get the error "Cannot find module 'prettier-plugin-tailwindcss'". I am using Vs Code. and developing with CRA.
My whole package.json
prettier.config.js
tailwind.config.js
postcss.config.js
The text was updated successfully, but these errors were encountered: