@source
does not scan node_modules
#19118
Replies: 5 comments
-
Hey! Can you share a minimal reproduction so we can take a look? That said, the better solution is to expose an You can use tailwindcss/packages/tailwindcss/package.json Lines 19 to 25 in d96a48e In your main package, you can then use a normal |
Beta Was this translation helpful? Give feedback.
-
Beta Was this translation helpful? Give feedback.
-
Is this on stackblitz or locally? |
Beta Was this translation helpful? Give feedback.
-
locally |
Beta Was this translation helpful? Give feedback.
-
Any possible solution to this case? |
Beta Was this translation helpful? Give feedback.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
What version of Tailwind CSS are you using?
4.1.13
What build tool (or framework if it abstracts the build tool) are you using?
Vite (nuxt 4.1.2)
What version of Node.js are you using?
v22.19.0
What browser are you using?
Brave
What operating system are you using?
Windows
Reproduction URL
Not available. Working locally.
Package structure
Describe your issue
Let me expose what I am trying to achieve.
I have a Nuxt base project on the one hand and on the other hand I have another Design System Nuxt project which works as a layer for the base project.
The Design system is created with Tailwind (4.1.13) and exported as a package.
This package is installed under node_modules. Everything works fine with the exception that Tailwind is unable to scan the node_modules folder using @source inside the main css file.
I have tried @source with a local layer (design system in a separate folder) and it works fine, Nevertheless, as soon as I try to use the node_module directory, it does not work, even if the Tailwind documentation (https://tailwindcss.com/docs/detecting-classes-in-source-files) explain you can do this.
So I guess this might be a bug.
Please, if you have another temporary solution to solve this issue, please let me know.
Beta Was this translation helpful? Give feedback.
All reactions