nuxt: 'nuxt dev' breaks on a fresh install with ssr: false

Environment


  • Operating System: Windows_NT
  • Node Version: v16.13.1
  • Nuxt Version: 3.0.0-rc.2
  • Package Manager: yarn@1.22.17
  • Builder: vite
  • User Config: ssr
  • Runtime Modules: -
  • Build Modules: -

Reproduction

https://github.com/mario-neuhold/nuxt3-starter/tree/v3

Describe the bug

nuxt dev is looking for .nuxt/dist/server/server.mjs which does not get created when ssr: false is on, so it crashes.

Workaround:

  • remove ssr: false
  • run nuxt dev - be happy its working (server.mjs got created)
  • add ssr: false again
  • nuxt dev is still working - keep on being happy (server.mjs is still there)

Reproduce:

  • delete .nuxt folder
  • be sure ssr: false is on
  • nuxt dev is not working anymore - be sad
  • start again with Workaround

Additional context

No response

Logs

ERROR Rollup error: Could not load file:///C:/Users/mario/Documents/dev/nuxt3-starter/.nuxt/dist/server/server.mjs: ENOENT: no such file or directory, open 'C:\Users\mario\Documents\dev\nuxt3-starter\file:\C:\Users\mario\Documents\dev\nuxt3-starter\.nuxt\dist\server\server.mjs'

About this issue

  • Original URL
  • State: closed
  • Created 2 years ago
  • Reactions: 16
  • Comments: 17 (4 by maintainers)

Most upvoted comments

This is a pretty critical bug - any updates?

This is a pretty critical bug - any updates?