nuxt/bridge - cannot find module 'nuxt' at startup
See original GitHub issueEnvironment
- Operating System:
Darwin
- Node Version:
v16.15.1
- Nuxt Version:
2.16.0-27610581.123206cb
- Package Manager:
npm@8.11.0
- Builder:
webpack
- User Config:
alias
,head
,css
,plugins
,components
,buildModules
,modules
,i18n
,axios
,build
,publicRuntimeConfig
,privateRuntimeConfig
,bridge
- Runtime Modules:
@nuxtjs/axios@5.13.6
,@nuxtjs/auth-next@5.0.0-1641536721.10cfcc9
,@nuxtjs/i18n@7.2.2
- Build Modules:
@nuxtjs/eslint-module@3.1.0
,@pinia/nuxt@0.1.9
,@nuxt/bridge@3.0.0-27611430.cf4761a
Reproduction
https://github.com/kadlinobit/djspot-fe/tree/vuex-to-pinia Branch: vuex-to-pinia
Describe the bug
After fresh installation, when running dev server (nuxi dev) there is an error:
ERROR Cannot start nuxt: Cannot find module 'nuxt' 19:47:24
Require stack:
- /Users/kadlec/projects/djspot-fe/index.js
Require stack:
- index.js
at Function.Module._resolveFilename (node:internal/modules/cjs/loader:933:15)
at Function.resolve (node:internal/modules/cjs/helpers:108:19)
at Function._resolve [as resolve] (node_modules/jiti/dist/jiti.js:1:108226)
at resolveModule (node_modules/@nuxt/kit/dist/index.mjs:276:29)
at importModule (node_modules/@nuxt/kit/dist/index.mjs:299:24)
at loadNuxt (node_modules/@nuxt/kit/dist/index.mjs:690:92)
at async load (node_modules/@nuxt/bridge/node_modules/nuxi/dist/chunks/dev.mjs:6740:23)
at async Object.invoke (node_modules/@nuxt/bridge/node_modules/nuxi/dist/chunks/dev.mjs:6786:5)
at async _main (node_modules/@nuxt/bridge/node_modules/nuxi/dist/cli.mjs:46:20)
Additional context
No response
Logs
Nuxt CLI v3.0.0-rc.4 19:47:24
19:47:24
> Local: http://localhost:3000/
> Network: http://192.168.0.102:3000/
ERROR Cannot start nuxt: Cannot find module 'nuxt' 19:47:24
Require stack:
- /Users/kadlec/projects/djspot-fe/index.js
Require stack:
- index.js
at Function.Module._resolveFilename (node:internal/modules/cjs/loader:933:15)
at Function.resolve (node:internal/modules/cjs/helpers:108:19)
at Function._resolve [as resolve] (node_modules/jiti/dist/jiti.js:1:108226)
at resolveModule (node_modules/@nuxt/kit/dist/index.mjs:276:29)
at importModule (node_modules/@nuxt/kit/dist/index.mjs:299:24)
at loadNuxt (node_modules/@nuxt/kit/dist/index.mjs:690:92)
at async load (node_modules/@nuxt/bridge/node_modules/nuxi/dist/chunks/dev.mjs:6740:23)
at async Object.invoke (node_modules/@nuxt/bridge/node_modules/nuxi/dist/chunks/dev.mjs:6786:5)
at async _main (node_modules/@nuxt/bridge/node_modules/nuxi/dist/cli.mjs:46:20)
Issue Analytics
- State:
- Created a year ago
- Reactions:11
- Comments:5 (2 by maintainers)
Top Results From Across the Web
cannot find module 'nuxt' at startup · Issue #380 · nuxt/bridge
I came back after vacation, tried fresh npm install again and the problem disappeared. Probably thanks to a new nuxt bridge version, this...
Read more >Error: Cannot find module nuxt.js, why my app don't start?
Try and install nuxt-start package. This is what I used to solve a very similar challenge (On Production).
Read more >@nuxt/bridge-edge - npm
Bridge is a forward-compatibility layer that allows you to experience many of the new Nuxt 3 features by simply installing and enabling a...
Read more >Migrate to Bridge: Overview - Nuxt
Bridge is a forward-compatibility layer that allows you to experience many of the new Nuxt 3 features by simply installing and enabling a...
Read more >cannot find module '@vue/composition-api' - You.com
Create simple application via yarn create nuxt-app; Add devDependencies via yarn add -D @nuxtjs/composition-api and add this dependency to buildModules in nuxt.
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
Author used nuxt 2 with bridge, which does not have nuxt3 or rc packages. But I got the same error yesterday in my nuxt2b app
I came back after vacation, tried fresh
npm install
again and the problem disappeared.Probably thanks to a new nuxt bridge version, this is my new
nuxi info
output:Previous nuxt bridge version: 3.0.0-27611430.cf4761a Current nuxt bridge version: 3.0.0-27621666.ee600b4