mirror of
https://github.com/cloudflare/vinext.git
synced 2026-05-09 00:09:23 +02:00
[PR #148] [MERGED] fix: decode request pathname once at entry point for consistent routing #346
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#346
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/148
Author: @southpolesteve
Created: 2/27/2026
Status: ✅ Merged
Merged: 2/27/2026
Merged by: @southpolesteve
Base:
main← Head:public/fix-decode-once-at-entry📝 Commits (1)
e90c2effix: decode request pathname once at entry point for consistent routing📊 Changes
6 files changed (+224 additions, -42 deletions)
View changed files
📝
packages/vinext/src/config/config-matchers.ts(+2 -1)📝
packages/vinext/src/index.ts(+13 -3)📝
packages/vinext/src/server/app-dev-server.ts(+11 -11)📝
packages/vinext/src/server/app-router-entry.ts(+13 -15)📝
packages/vinext/src/server/middleware.ts(+10 -1)📝
tests/shims.test.ts(+175 -11)📄 Description
Summary
decodeURIComponent+normalizePath) at the request entry pointdecodeURIComponentcalls frommatchRouteandmatchConfigPatterncatch-all branchesPreviously, some code paths decoded the pathname a second time, which could cause inconsistent matching between middleware and routing when percent-encoded characters were present in the URL.
🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.