next.js icon indicating copy to clipboard operation
next.js copied to clipboard

Output export and distDir in the config file will crash the dev server (Ver 14.1)

Open leo-budgetsimple opened this issue 1 year ago • 1 comments

Link to the code that reproduces this issue

https://github.com/leo-budgetsimple/nextjs-bug

To Reproduce

Copy over the repo

Start the application on dev (npm run dev)

Go to localhost:3000

You should see the text 'Hello'

but instead you get: missing required error components, refreshing...

Current vs. Expected behavior

Current Behavior:

Cannot run development server, this error appears on the screen:

missing required error components, refreshing...

Expected Behaviour

To be able to run the dev server.

Provide environment information

Operating System:
  Platform: linux
  Arch: x64
  Version: #15~22.04.1-Ubuntu SMP PREEMPT_DYNAMIC Fri Jan 12 18:54:30 UTC 2
Binaries:
  Node: 18.19.0
  npm: 10.2.3
  Yarn: N/A
  pnpm: N/A
Relevant Packages:
  next: 14.1.1-canary.47 // Latest available version is detected (14.1.1-canary.47).
  eslint-config-next: N/A
  react: 18.2.0
  react-dom: 18.2.0
  typescript: 5.1.3
Next.js Config:
  output: export

Which area(s) are affected? (Select all that apply)

Static HTML Export (output: "export")

Which stage(s) are affected? (Select all that apply)

next dev (local)

Additional context

This happened after I upgraded to NextJs 14.1.

Doesn't happen with old versions.

If I remove distDir the dev server works as intended, same as if I remove the output: export

leo-budgetsimple avatar Feb 11 '24 10:02 leo-budgetsimple

Would love to have some feedback, I got the same problem on my frontend react strapi website

drmahikbov avatar Feb 16 '24 18:02 drmahikbov

I have the same issue the dev server is looking for build/server/middleware-manifest.json instead of .next/server/middleware-manifest.json

atstoyanov avatar Feb 17 '24 14:02 atstoyanov

Any solution?

Edit by maintainer bot: Comment was automatically minimized because it was considered unhelpful. (If you think this was by mistake, let us know). Please only comment if it adds context to the issue. If you want to express that you have the same problem, use the upvote 👍 on the issue description or subscribe to the issue for updates. Thanks!

KevenGoncalves avatar Feb 19 '24 07:02 KevenGoncalves

Closing as this is fixed in latest canary of Next.js, x-ref: https://github.com/vercel/next.js/issues/61105#issuecomment-1945172916

ijjk avatar Feb 23 '24 07:02 ijjk

This closed issue has been automatically locked because it had no new activity for 2 weeks. If you are running into a similar issue, please create a new issue with the steps to reproduce. Thank you.

github-actions[bot] avatar Mar 09 '24 00:03 github-actions[bot]