next.js
next.js copied to clipboard
Next.js 13 stuck at `Creating an optimized production build...` when building with `swcMinify`
Verify canary release
- [X] I verified that the issue exists in the latest Next.js canary release
Provide environment information
Operating System:
Platform: win32
Arch: x64
Version: Windows 10 Pro
Binaries:
Node: 18.12.0
npm: 8.19.2
Yarn: 1.22.19
pnpm: 7.14.1
Relevant packages:
next: 13.0.0 (13.0.1-canary.1)
eslint-config-next: 13.0.0
react: 18.2.0
react-dom: 18.2.0
What browser are you using? (if relevant)
Chrome 107.0.5304.88
How are you deploying your application? (if relevant)
Vercel
Describe the Bug
Running next build will freeze at Creating an optimized production build... but will build successfully after disable the SWC Minifier in next.config.js.
Similar with issue https://github.com/vercel/next.js/issues/37825 but, the build will always be stuck whether the development server is running or not.
Refer to https://github.com/nextui-org/nextui/issues/848
Expected Behavior
Build successfully when using SWC Minifier.
Link to reproduction
https://codesandbox.io/s/quizzical-tess-nnw9js
To Reproduce
CodeSandbox
- Fork and add a new terminal then run
yarn build
Locally
- Export the CodeSandbox project
pnpm install && pnpm build
How to export the project from the CodeSandbox to local?
