Skip to content

Conversation

@SoonIter
Copy link
Member

Summary

fix(route): should be compatiable to lowercase routePath

Related Issue

Checklist

  • Tests updated (or not required).
  • Documentation updated (or not required).

Copilot AI review requested due to automatic review settings November 18, 2025 07:18
@netlify
Copy link

netlify bot commented Nov 18, 2025

Deploy Preview for rspress-v2 ready!

Name Link
🔨 Latest commit 36d060f
🔍 Latest deploy log https://app.netlify.com/projects/rspress-v2/deploys/691c1dbc05c6df00080bc34a
😎 Deploy Preview https://deploy-preview-2776--rspress-v2.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify project configuration.

@github-actions
Copy link
Contributor

Rsdoctor Bundle Diff Analysis

📁 web

Path: website/doc_build/web/rsdoctor-data.json

⚠️ No baseline data found - Unable to perform comparison analysis

Metric Current Baseline Change
📊 Total Size 14.3 MB - -
📄 JavaScript 13.7 MB - -
🎨 CSS 109.0 KB - -
🌐 HTML 0 B - -
📁 Other Assets 496.7 KB - -

Generated by Rsdoctor GitHub Action

Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull Request Overview

This PR adds case-insensitive route matching to handle scenarios where URLs may use different casing. The implementation converts route paths to lowercase during normalization and comparison.

Key changes:

  • Modified normalizeRoutePath to convert paths to lowercase for case-insensitive matching
  • Updated matchPath, pathnameToRouteService, and isActive functions to use normalized paths for comparison
  • Added comprehensive test coverage for case-insensitive matching scenarios

Reviewed Changes

Copilot reviewed 2 out of 2 changed files in this pull request and generated 1 comment.

File Description
packages/runtime/src/route.ts Implements case-insensitive route matching by adding .toLowerCase() to path normalization and updating all matching functions to use normalized paths
packages/runtime/src/route.test.ts Adds test cases validating case-insensitive matching behavior across all route matching functions

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@SoonIter SoonIter merged commit 8310b39 into main Nov 18, 2025
16 checks passed
@SoonIter SoonIter deleted the syt/fix-lower-case branch November 18, 2025 11:44
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants