Optimistic routing (instant loading states for unprefetched routes) not implemented
#1,360 opened on May 20, 2026
Repository metrics
- Stars
- (8,563 stars)
- PR merge metrics
- (Avg merge 1d 1h) (462 merged PRs in 30d)
Description
This issue was created by an agent analysing CI failures from the Next.js Deploy Suite (vinext
mainvs Next.jsv16.2.6, 2026-05-20).
Problem
Optimistic routing (a Next.js feature that shows instant loading states for dynamic routes that haven't been prefetched) is not implemented. Tests time out waiting for the optimistic loading state to appear when navigating to unprefetched dynamic routes.
Timed out waiting for a request to be initiated.
// The act() helper times out because no optimistic navigation occurs
Estimated Impact
~7 test failures.
Affected Test Suites
test/e2e/app-dir/optimistic-routing/optimistic-routing.test.ts(7 failures)
Recommendation
-
Reproduce first in vinext's own test suite. Add a test that navigates to an unprefetched dynamic route and asserts a loading state appears immediately. Confirm it fails.
-
Study the Next.js optimistic routing implementation. Search
.nextjs-ref/packages/next/src/client/for optimistic routing and loading state prediction. -
This is a client-side router feature. It requires the client-side router to optimistically render the nearest loading boundary for unprefetched routes while the RSC payload is being fetched.