Link to the code that reproduces this issue
https://github.com/devjiwonchoi/repro-next-turbo-mdx-remote-rsc
To Reproduce
pnpm i
pnpm dev
- Open
http://localhost:3000
Current vs. Expected behavior
Current
Package next-mdx-remote (serverComponentsExtenalPackages or default list) can't be external
The request next-mdx-remote/rsc matches serverComponentsExtenalPackages (or the default list), but it can't be external:
The package seems invalid. require() resolves to a EcmaScript module, which would result in an error in Node.js.
Expected
It should not throw
Provide environment information
Operating System:
Platform: darwin
Arch: arm64
Version: Darwin Kernel Version 23.1.0: Mon Oct 9 21:32:11 PDT 2023; root:xnu-10002.41.9~7/RELEASE_ARM64_T6030
Available memory (MB): 18432
Available CPU cores: 11
Binaries:
Node: 18.17.0
npm: 9.6.7
Yarn: 1.22.19
pnpm: 8.15.4
Relevant Packages:
next: 14.2.0-canary.23 // Latest available version is detected (14.2.0-canary.23).
eslint-config-next: N/A
react: 18.2.0
react-dom: 18.2.0
typescript: 5.4.2
Next.js Config:
output: N/A
Which area(s) are affected? (Select all that apply)
Turbopack (--turbo)
Which stage(s) are affected? (Select all that apply)
next dev (local)
Additional context
This issue has been introduced at next@14.1.1-canary.64
Related PR: #62235
This works when using webpack only (next dev)
PACK-2927
Link to the code that reproduces this issue
https://github.com/devjiwonchoi/repro-next-turbo-mdx-remote-rsc
To Reproduce
pnpm ipnpm devhttp://localhost:3000Current vs. Expected behavior
Current
Expected
It should not throw
Provide environment information
Operating System: Platform: darwin Arch: arm64 Version: Darwin Kernel Version 23.1.0: Mon Oct 9 21:32:11 PDT 2023; root:xnu-10002.41.9~7/RELEASE_ARM64_T6030 Available memory (MB): 18432 Available CPU cores: 11 Binaries: Node: 18.17.0 npm: 9.6.7 Yarn: 1.22.19 pnpm: 8.15.4 Relevant Packages: next: 14.2.0-canary.23 // Latest available version is detected (14.2.0-canary.23). eslint-config-next: N/A react: 18.2.0 react-dom: 18.2.0 typescript: 5.4.2 Next.js Config: output: N/AWhich area(s) are affected? (Select all that apply)
Turbopack (--turbo)
Which stage(s) are affected? (Select all that apply)
next dev (local)
Additional context
This issue has been introduced at
next@14.1.1-canary.64Related PR: #62235
This works when using
webpackonly (next dev)PACK-2927