Nuxt 3 issue "Cannot read property 'resolveAlias' of undefined"
See original GitHub issueVersion
@nuxtjs/tailwindcss: 4.2.1 nuxt: nuxt3@3.0.0-27234271.da7ff44
Reproduction Link
https://codesandbox.io/s/hungry-diffie-k8odx
Steps to reproduce
none
What is Expected?
no error to be produced
What is actually happening?
error is produced:
ERROR Cannot restart nuxt: Cannot read property 'resolveAlias' of undefined
at Object.tailwindCSSModule (node_modules/@nuxtjs/tailwindcss/dist/index.js:51:36)
at installModule (node_modules/@nuxt/kit/dist/index.mjs:1196:17)
at initNuxt (node_modules/nuxt3/dist/index.mjs:817:11)
at processTicksAndRejections (node:internal/process/task_queues:96:5)
at async load (node_modules/nuxi/dist/chunks/dev.mjs:6762:9)
Issue Analytics
- State:
- Created 2 years ago
- Reactions:53
- Comments:29 (3 by maintainers)
Top Results From Across the Web
Nuxt 3 issue "Cannot read property 'resolveAlias' of undefined"
Create your configuration file: npx tailwindcss init -p; Configure Tailwind to remove unused styles in production. // tailwind.config.js module.
Read more >vue nuxt TypeError: Cannot read properties of undefined ...
Answering myself. It was just required to use auth-next instead of auth. '@nuxtjs/auth-next',.
Read more >The alias Property - Nuxt
This option lets you define aliases to directories within your project (in addition to the ones above). These aliases can be used within...
Read more >Resolve | webpack
Setting resolve.alias to false will tell webpack to ignore a module. ... When the target property is set to webworker , web ,...
Read more >Introduction to Nuxt 3 modules - DEV Community
I only get Unresolved variable $strapi / Cannot read properties of undefined (reading '$strapi') error messages. Do you have any idea what the ......
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
Thank you @productfrontenddeveloper
What got it working for my repo was:
I’m still learning
nuxt
but thatbuild
definition seemed to get things runningI think this package is no longer needed, because nuxt now uses webpack 5 and already supports tailwindcss. Install tailwind as next.js:
npm install -D tailwindcss@latest postcss@latest autoprefixer@latest
npx tailwindcss init -p