From 7f6e52f1a10408f116f7f0f9e723eec69d9b83c8 Mon Sep 17 00:00:00 2001 From: hiro-nikaitou Date: Mon, 6 Jul 2026 23:03:12 +0800 Subject: [PATCH 1/2] fix(routing): normalize path.relative() results in app-route-graph for Windows compat --- packages/vinext/src/routing/app-route-graph.ts | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/packages/vinext/src/routing/app-route-graph.ts b/packages/vinext/src/routing/app-route-graph.ts index 94799a3a33..1d7b2243db 100644 --- a/packages/vinext/src/routing/app-route-graph.ts +++ b/packages/vinext/src/routing/app-route-graph.ts @@ -1202,7 +1202,7 @@ function discoverSlotSubRoutes( const subPages = findSlotSubPages(slotDir, matcher); for (const { relativePath, pagePath } of subPages) { - const subSegments = relativePath.split(path.sep); + const subSegments = relativePath.split("/"); const convertedSubRoute = convertSegmentsToRouteParts(subSegments); if (!convertedSubRoute) continue; @@ -1490,7 +1490,7 @@ function findSlotSubPages(slotDir: string, matcher: ValidFileMatcher): SlotSubPa const subDir = path.join(dir, entry.name); const page = findFile(subDir, "page", matcher); if (page) { - const relativePath = path.relative(slotDir, subDir); + const relativePath = normalizePathSeparators(path.relative(slotDir, subDir)); results.push({ relativePath, pagePath: page }); } // Continue scanning deeper for nested sub-pages @@ -1525,8 +1525,8 @@ function findSlotConfigLayoutTreePositions( layoutPaths: readonly string[], ): number[] { return layoutPaths.map((layoutPath) => { - const relativeDir = path.relative(slotDir, path.dirname(layoutPath)); - return relativeDir ? relativeDir.split(path.sep).filter(Boolean).length : 0; + const relativeDir = normalizePathSeparators(path.relative(slotDir, path.dirname(layoutPath))); + return relativeDir ? relativeDir.split("/").filter(Boolean).length : 0; }); } @@ -1812,8 +1812,8 @@ function computeLayoutTreePositions(appDir: string, layouts: string[]): number[] return layouts.map((layoutPath) => { const layoutDir = path.dirname(layoutPath); if (layoutDir === appDir) return 0; - const relative = path.relative(appDir, layoutDir); - return relative.split(path.sep).length; + const relative = normalizePathSeparators(path.relative(appDir, layoutDir)); + return relative.split("/").length; }); } @@ -2149,7 +2149,7 @@ function findMirroredSlotPage( }; let best: Candidate | null = null; for (const { relativePath, pagePath } of findSlotSubPages(slotDir, matcher)) { - const slotSegments = relativePath.split(path.sep); + const slotSegments = relativePath.split("/"); const slotUrl = convertSegmentsToRouteParts(slotSegments); if (!slotUrl) continue; if (!patternsCompatible(slotUrl.urlSegments, routeUrl.urlSegments)) continue; From 0320298adb4e43953f9c58bdb1da84257431a730 Mon Sep 17 00:00:00 2001 From: hiro-nikaitou Date: Tue, 7 Jul 2026 09:55:40 +0800 Subject: [PATCH 2/2] keep .github/workflows/perf.yml at fork's version (avoid PAT workflow scope) --- .github/workflows/perf.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/perf.yml b/.github/workflows/perf.yml index 037bb032e0..5d17b85037 100644 --- a/.github/workflows/perf.yml +++ b/.github/workflows/perf.yml @@ -198,7 +198,7 @@ jobs: done - name: Setup Vite+ - uses: voidzero-dev/setup-vp@250f29ce396baf5e8f24498e17c0dfdebabc26eb # v1 + uses: voidzero-dev/setup-vp@35171c92dd08b67d5a9d3f2a4327800e58396f2a # v1 with: node-version: "24" cache: true