-
Notifications
You must be signed in to change notification settings - Fork 271
Open
Labels
Description
bug
When attempting to run Next.js 16 with the Turbopack engine (--turbo) inside a WebContainer environment (StackBlitz), the initialization process fails. The runtime throws an error indicating that the turbo.createProject method is not supported by the current WebAssembly (WASM) bindings.
This issue prevents developers from using the new Turbopack features in browser-based IDEs, which are essential for quick prototyping and collaborative debugging.
Link to the blitz that caused the error
Proyect private.
Steps to reproduce
To Reproduce
- Open a Next.js 16.x project in StackBlitz.
- Run
npm install. - Start the development server with Turbopack:
npx next dev --turbo. - Observe the crash during the "Starting..." phase.
Expected behavior
Expected Behavior
Turbopack should initialize correctly using WASM-compatible bindings, or Next.js should provide a graceful fallback/descriptive warning if specific native Rust features are not yet available in the WebContainer sandbox.
Parity with Local
- I have run the project in my local machine and I could not reproduce the issue.
Screenshots
Screenshots / Logs
▲ Next.js 16.1.6 (Turbopack)
- Local: http://localhost:3000
- Environments: .env
✓ Starting...
Downloading swc package @next/swc-wasm-nodejs... to /home/.cache/next-swc
Skipping creating a lockfile at /home/project/.next/dev/lock because we're using WASM bindings
Error: `turbo.createProject` is not supported by the wasm bindings.
at ignore-listed frames
### Platform
Platform: StackBlitz (WebContainers)
Next.js Version: 16.1.6
Package Manager: npm
Engine: Turbopack (WASM)
### Additional context
The error suggests that the @next/swc-wasm-nodejs package or the internal Turbo Rust bindings are attempting to call a native-only function (createProject) that hasn't been implemented or exposed for the WASM target used by WebContainers. This effectively blocks the use of Turbopack in any browser-based development environmentReactions are currently unavailable