mirror of
https://github.com/cloudflare/vinext.git
synced 2026-05-09 08:25:34 +02:00
[PR #928] [MERGED] fix(router): reject invalid app route discovery conflicts #958
Labels
No labels
enhancement
enhancement
good first issue
help wanted
nextjs-tracking
nextjs-tracking
pull-request
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
starred/vinext#958
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
📋 Pull Request Information
Original PR: https://github.com/cloudflare/vinext/pull/928
Author: @NathanDrake2406
Created: 4/28/2026
Status: ✅ Merged
Merged: 4/28/2026
Merged by: @james-elicx
Base:
main← Head:nathan/app-router-validation-parity📝 Commits (2)
4ca3709fix(router): reject invalid app route discovery conflicts40d91fdfix(router): address app route validation review📊 Changes
2 files changed (+197 additions, -0 deletions)
View changed files
📝
packages/vinext/src/routing/app-router.ts(+91 -0)📝
tests/routing.test.ts(+106 -0)📄 Description
Summary
( .. )-style upward markers after the normalized route has no visible segment left to climb.pageandroutefiles resolve to the same App Router path.Root cause / Why
vinext already resolved interception targets by visible route segments, but it kept resolving at root when
( .. )or( .. )( .. )tried to climb past the normalized intercepting route. Next.js validates the normalized interception route first and throws explicit marker errors instead of silently resolving from root.vinext also discovered
pageandroutefiles as separate entries and deferred conflict detection to the generic duplicate route pattern validator. That produced a correct rejection but not the explicit App Router conflict that points at the page and route handler files.Next.js parity references:
Verification
vp test run tests/routing.test.tsvp test run tests/route-sorting.test.tsvp check tests/routing.test.ts packages/vinext/src/routing/app-router.ts🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.