ITADN

Infinite reload loop in Firefox with loading.tsx and slow async Server Components

#95164Closedsoberm 创建于 2026-06-25
Loading UI and Streaming
S
sobermcommented
### Link to the code that reproduces this issue https://github.com/soberm/nextjs-firefox-loading-loop-repro ### To Reproduce 1. Clone the reproduction repo and run `npm install` 2. Start the dev server with `npm run dev` 3. Open http://localhost:3000 in **Firefox** (use incognito/private window) 4. Observe the page entering an infinite reload loop — "Loading..." flashes repeatedly, and the Network tab shows the document being requested over and over ### Current vs. Expected behavior **Current:** In Firefox, when a `loading.tsx` Suspense boundary is present and a Server Component has an async operation taking ≥200ms (e.g., a database query, API call, or even a simple `setTimeout(500)`), the page enters an infinite reload loop. The loading fallback flashes repeatedly and the page never stabilizes. **Expected:** The page should render the loading fallback initially, then stream the final content once the async work completes — the same behavior observed in Chrome/Chromium. The issue is Firefox-specific. Chrome handles the same code correctly. ### Provide environment information ```bash Operating System: Platform: darwin Arch: arm64 Version: Darwin Kernel Version 25.5.0 Available memory (MB): 36864 Available CPU cores: 12 Binaries: Node: 24.15.0 npm: 11.12.1 Yarn: 1.22.22 pnpm: 11.9.0 Relevant Packages: next: 16.2.9 // Latest available version is detected (16.2.9). eslint-config-next: N/A react: 19.2.7 react-dom: 19.2.7 typescript: 6.0.3 Next.js Config: output: N/A ``` ### Which area(s) are affected? (Select all that apply) Loading UI and Streaming ### Which stage(s) are affected? (Select all that apply) next dev (local) ### Additional context _No response_
关闭于 2026-06-25 3 条评论