Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Resolvers can return redirect command #54556

Closed

Conversation

atscott
Copy link
Contributor

@atscott atscott commented Feb 22, 2024

Returning a RedirectCommand from a resolver can be interpreted as
distinctly different from regular resolved data. When a resolver returns
RedirectCommand we can interperet this as an intention to redirect in
the same way as other guards.

resolves #29089

@atscott atscott added state: blocked area: core Issues related to the framework runtime target: major This PR is targeted for the next major release labels Feb 22, 2024
@ngbot ngbot bot added this to the Backlog milestone Feb 22, 2024
@angular-robot angular-robot bot added detected: breaking change PR contains a commit with a breaking change detected: feature PR contains a feature commit labels Feb 22, 2024
Returning a `RedirectCommand` from a resolver can be interpreted as
distinctly different from regular resolved data. When a resolver returns
`RedirectCommand` we can interperet this as an intention to redirect in
the same way as other guards.

resolves angular#29089
@atscott atscott force-pushed the resolversCanReturnRedirectCommand branch from 9da6905 to 935e13e Compare March 21, 2024 15:44
@angular-robot angular-robot bot removed the detected: breaking change PR contains a commit with a breaking change label Mar 21, 2024
@atscott atscott marked this pull request as ready for review March 21, 2024 15:45
Copy link
Contributor

@jessicajaniuk jessicajaniuk left a comment

Choose a reason for hiding this comment

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

reviewed-for: public-api

@pullapprove pullapprove bot requested a review from alxhub March 25, 2024 21:07
@atscott
Copy link
Contributor Author

atscott commented Mar 25, 2024

Copy link
Member

@pkozlowski-opensource pkozlowski-opensource 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: public-api

@atscott atscott added the action: merge The PR is ready for merge by the caretaker label Mar 29, 2024
@atscott
Copy link
Contributor Author

atscott commented Mar 30, 2024

This PR was merged into the repository by commit 87f3f27.

@atscott atscott closed this in 87f3f27 Mar 30, 2024
ilirbeqirii pushed a commit to ilirbeqirii/angular that referenced this pull request Apr 6, 2024
)

Returning a `RedirectCommand` from a resolver can be interpreted as
distinctly different from regular resolved data. When a resolver returns
`RedirectCommand` we can interperet this as an intention to redirect in
the same way as other guards.

resolves angular#29089

PR Close angular#54556
@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 Apr 30, 2024
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: core Issues related to the framework runtime detected: feature PR contains a feature commit target: major This PR is targeted for the next major release
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Router Resolve<T> should have official support for UrlTree based redirection
3 participants