[pull] main from remix-run:main - #311
Merged
Merged
Conversation
* docs: add Hostinger as a hosting provider for deploying Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com> * Sign the CLA Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com> --------- Co-authored-by: Claude Opus 4.8 <noreply@anthropic.com>
…#15267) * docs: improve useMatches conceptual explanation and examples * chore: sign CLA * docs: fix jsx syntax, apply typeof filter, and clean whitespace in useMatches * Update docs * Update docs --------- Co-authored-by: Matt Brophy <matt@brophy.org>
* feat: add default server entry for non-Node runtimes * remove node runtime check from default server entry * update contributors.yml * improve runtime detection in default server entries * improve the name of the added test * Updates * add change file * reorder * Switch to web streams * Realign import * Update change file * Remove uneccesary playground entry * Fix E2E tests * Updatre change file * Another update --------- Co-authored-by: Matt Brophy <matt@brophy.org>
… compilePath (#15200) * fix(router): use non-capturing groups for optional static segments in compilePath When a route path contains optional static segments (e.g. `/school?/user/:id`), compilePath was generating capturing groups `(\/school)?` for those segments. This shifted the capture group indices used to extract dynamic params, causing matchPath to return wrong param values — e.g. `params.id` would be `"/school"` instead of the correct value. Additionally, consecutive optional static segments (e.g. `/one?/two?`) were only partially handled: only the first optional segment was wrapped in an optional group because the global regex consumed the `/` separator. Subsequent segments' `?` were left as unescaped regex quantifiers, making the last letter of the segment optional in the regex rather than the whole segment. Fix: change the optional static segment replacement in compilePath to use: - Non-capturing groups `(?:/$1)?` so capture group indices are not shifted - A lookahead `(?=\/|$|\()` (instead of consuming the separator) so consecutive optional statics and those followed by optional dynamic params are handled * Sign CLA * Updte change file --------- Co-authored-by: JSap0914 <JSap0914@users.noreply.github.com> Co-authored-by: Matt Brophy <matt@brophy.org>
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 subscribe to this conversation on GitHub.
Already have an account?
Sign in.
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.
See Commits and Changes for more details.
Created by
pull[bot] (v2.0.0-alpha.4)
Can you help keep this open source service alive? 💖 Please sponsor : )