Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Conversation

@atscott
Copy link
Contributor

@atscott atscott commented Oct 15, 2025

Previously, query parameters passed to router.createUrlTree were simply converted to strings. This meant that any custom serialization logic in a custom UrlSerializer was not applied. This could lead to inconsistencies between navigations triggered from the URL bar (which are parsed by the serializer) and navigations triggered programmatically.

This change ensures that query parameters are normalized using the provided UrlSerializer. The values are serialized and then parsed to ensure they are in the same format as if they had come from a URL. This allows custom serializers to handle complex objects in query parameters consistently.

Fixes #47307

@atscott atscott added the requires: TGP This PR requires a passing TGP before merging is allowed label Oct 15, 2025
@ngbot ngbot bot added this to the Backlog milestone Oct 15, 2025
@atscott atscott force-pushed the objectqueryparams branch 3 times, most recently from 8f36ff9 to 6e5e777 Compare October 15, 2025 20:59
Previously, query parameters passed to `router.createUrlTree` were simply converted to strings. This meant that any custom serialization logic in a custom `UrlSerializer` was not applied. This could lead to inconsistencies between navigations triggered from the URL bar (which are parsed by the serializer) and navigations triggered programmatically.

This change ensures that query parameters are normalized using the provided `UrlSerializer`. The values are serialized and then parsed to ensure they are in the same format as if they had come from a URL. This allows custom serializers to handle complex objects in query parameters consistently.

Fixes angular#47307
@atscott atscott marked this pull request as ready for review October 17, 2025 15:22
@pullapprove pullapprove bot removed the requires: TGP This PR requires a passing TGP before merging is allowed label Oct 17, 2025
@atscott atscott added target: major This PR is targeted for the next major release risky Identifies a PR that has a level of risk to merging labels Oct 17, 2025
@atscott
Copy link
Contributor Author

atscott commented Oct 17, 2025

TGP=https://fusion2.corp.google.com/presubmit/819873106/OCL:819873106:BASE:820699422:1760714504979:cdb84a9f/targets

Targeting major and marking risky despite the green TGP.

Copy link
Contributor

@thePunderWoman thePunderWoman left a comment

Choose a reason for hiding this comment

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

LGTM

reviewed-for: fw-general, public-api

@thePunderWoman thePunderWoman removed the request for review from mmalerba October 17, 2025 16:06
@thePunderWoman thePunderWoman added the action: merge The PR is ready for merge by the caretaker label Oct 17, 2025
@thePunderWoman
Copy link
Contributor

This PR was merged into the repository. The changes were merged into the following branches:

thePunderWoman added a commit to thePunderWoman/angular that referenced this pull request Oct 18, 2025
@thePunderWoman thePunderWoman added action: cleanup The PR is in need of cleanup, either due to needing a rebase or in response to comments from reviews and removed action: merge The PR is ready for merge by the caretaker labels Oct 18, 2025
thePunderWoman added a commit that referenced this pull request Oct 18, 2025
@atscott atscott added action: merge The PR is ready for merge by the caretaker and removed action: cleanup The PR is in need of cleanup, either due to needing a rebase or in response to comments from reviews labels Oct 18, 2025
@thePunderWoman
Copy link
Contributor

This PR was merged into the repository. The changes were merged into the following branches:

@angular-automatic-lock-bot
Copy link

This issue has been automatically locked due to inactivity.
Please file a new issue if you are encountering a similar or related problem.

Read more about our automatic conversation locking policy.

This action has been performed automatically by a bot.

@angular-automatic-lock-bot angular-automatic-lock-bot bot locked and limited conversation to collaborators Nov 20, 2025
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

action: merge The PR is ready for merge by the caretaker area: router risky Identifies a PR that has a level of risk to merging target: major This PR is targeted for the next major release

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Support for object in queryParams

2 participants

Morty Proxy This is a proxified and sanitized view of the page, visit original site.