Repository navigation
fix(trie-router): match suffix wildcard routes - #5236
Merged
Merged
Conversation
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
Codecov Report❌ Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #5236 +/- ##
==========================================
+ Coverage 79.77% 79.80% +0.02%
==========================================
Files 155 155
Lines 10934 10898 -36
Branches 2292 2290 -2
==========================================
- Hits 8723 8697 -26
+ Misses 2211 2201 -10 ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
3 tasks done
3 tasks done
…ndle-size refactor(trie-router): trade registration speed for bundle size
…le-size refactor: Reduce TrieRouter bundle size without a meaningful performance regression
Bundle size check
Compiler Diagnostics (tsc)
Compiler Diagnostics (typescript-go)
Reported by octocov |
HTTP Performance Benchmark
|
Member
Author
|
Hi @yusukebe, I've merged the following two pull requests here.
Please review these changes! |
Member
@usualoma Woooow great! Thanks! |
3 of 4 tasks
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.

Fixes #5219
This PR makes TrieRouter recognize a terminal segment ending in
*as a suffix wildcard. The prefix is matched literally, so regular expression characters have no special meaning.There are already two PRs addressing this issue (#5220 and #5230), but they either have a larger implementation footprint or do not cover all relevant cases. This approach is more compact and keeps the fix narrowly scoped to TrieRouter.
It slightly increases the bundle size, but planned follow-up PRs should more than offset that increase.
The author should do the following, if applicable
bun run format:fix && bun run lint:fixto format the code