Module Import issues "Cannot find module '@unhead/vue'"
ffoerster opened this issue · 3 comments
ffoerster commented
Describe the bug
Hey harlan-zw,
thanks for your great work with the SEO module! I have been running into issues after upgrading the main SEO Module to RC and Nuxt to 3.9.0.
Not sure if it should be filed here or rather in the main @nuxtjs/seo.
[13:48:26] ERROR Error while requiring module /home/projects/nuxt-3-gnd2fx/node_modules/nuxt-schema-org/dist/module.mjs: Error: Cannot find module '@unhead/vue'
Require stack:
- /home/projects/nuxt-3-gnd2fx/node_modules/@unhead/schema-org/dist/vue.cjs
ERROR Cannot start nuxt: Cannot find module '@unhead/vue' 13:48:26
Require stack:
- /home/projects/nuxt-3-gnd2fx/node_modules/@unhead/schema-org/dist/vue.cjs
Require stack:
- node_modules/@unhead/schema-org/dist/vue.cjs
at Module._resolveFilename (https://nuxt3gnd2fx-1hw3-y1d3di8s.w-credentialless.staticblitz.com/blitz.f7aa08df.js:55:12642)
at Function.resolve (https://nuxt3gnd2fx-1hw3-y1d3di8s.w-credentialless.staticblitz.com/blitz.f7aa08df.js:98:2256)
at _resolve (node_modules/jiti/dist/jiti.js:1:251223)
at jiti (node_modules/jiti/dist/jiti.js:1:253821)
at eval (node_modules/@unhead/schema-org/dist/vue.cjs:4:13)
at evalModule (node_modules/jiti/dist/jiti.js:1:256518)
at jiti (node_modules/jiti/dist/jiti.js:1:254446)
at eval (node_modules/nuxt-schema-org/dist/module.mjs:2:12)
at evalModule (node_modules/jiti/dist/jiti.js:1:256518)
at jiti (node_modules/jiti/dist/jiti.js:1:254446)
Reproduction
https://stackblitz.com/edit/nuxt-3-gnd2fx
System / Nuxt Info
Nuxt project info: 13:52:54
------------------------------
- Operating System: Linux
- Node Version: v18.18.0
- Nuxt Version: 3.9.1
- CLI Version: 3.10.0
- Nitro Version: 2.8.1
- Package Manager: npm@9.4.2
- Builder: -
- User Config: modules
- Runtime Modules: @nuxtjs/seo@2.0.0-rc.4
- Build Modules: -
------------------------------
ffoerster commented
Sorry for the pointless issue spam - i think my lockfile was just messed up.
harlan-zw commented
All good, glad you could get it working 🙂
greetfish commented
I drop package-lock.json file and node_modules/ than run npm i,it working