N
Nuxt8mo ago
Reeed

can't find module tailwindcss

after i installed the @nuxt/ui module, i tried to import some types from tailwindcss like this import type {Config} from 'tailwindcss', but it didn't work, so tailwindcss is apparently missing and i'm not sure if i should install tailwindcss again to use the types. don't know what i'm missing here
4 Replies
Lapor
Lapor8mo ago
If I remember correctly, try removing tailwind package and replace it with tailwind nuxt module?
Reeed
Reeed8mo ago
i didn't install tailwindcss in the first place
Lapor
Lapor8mo ago
Sorry. I mistake the stuff on Nuxt UI. Just the confirm, do you have tailwindcss module for Nuxt? If so, you'll need to remove it. You should remove them from your modules and dependencies if you've previously installed them. https://ui.nuxt.com/getting-started/installation#modules
Nuxt UI
Installation - Nuxt UI
Learn how to install and configure Nuxt UI in your application.
Nook
Nook8mo ago
that is because underlying dependencies are not hoisted to your project's level. You could install it as a dev dependency and only import the types, the build will not add Tailwind twice anyway. Or, you could add this line in your .npmrc
[.npmrc]
shamefully-hoist=true
[.npmrc]
shamefully-hoist=true
And reinstall dependencies
Want results from more Discord servers?
Add your server