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鈥檒l occasionally send you account related emails.

Already on GitHub? Sign in to your account

Url is only updated the first time with UrlUpdateStrategy = "eager" #27116

Closed
marcinsydor opened this Issue Nov 15, 2018 · 1 comment

Comments

Projects
None yet
3 participants
@marcinsydor
Copy link

marcinsydor commented Nov 15, 2018

馃悶 bug report

Affected Package

The issue is caused by package @angular/router

Is this a regression?

It's a new future in ^7.1.0-rc.0

Description

I have "protected" page and a guard which returns UrlTree object after 3s. As I expect the first time when I click "protected" link the url is updated to /protected and after 3 seconds to /login segment. And I see the login page content.

When I click again "protected" link the url is changed to /protected but after 3 seconds the segment remaind the same. I think it sould see /login segment again.

馃敩 Minimal Reproduction

https://stackblitz.com/edit/angular-routing-eager-strategy

@ngbot ngbot bot added this to the needsTriage milestone Nov 16, 2018

@jasonaden

This comment has been minimized.

Copy link
Contributor

jasonaden commented Nov 27, 2018

Awesome issue. Thanks for this one! I'll mark this for our next iteration and it should be pulled in within a couple weeks.

@ngbot ngbot bot modified the milestones: needsTriage, Backlog Nov 27, 2018

jasonaden added a commit to jasonaden/angular that referenced this issue Dec 6, 2018

fix(router): ensure URL is updated after second redirect with UrlUpda鈥
鈥eStrategy="eager"

Navigating to a route such as `/users`, you may get redirected to `/login`. Previously, if you go then route to `/users` again the URL will end up showing `/users` after the second redirect. This only happened in `UrlUpdateStrategy="eager"`. This is now fixed so after the second redirect, the URL shows the correct page.

Fixes angular#27116

jasonaden added a commit to jasonaden/angular that referenced this issue Dec 6, 2018

fix(router): ensure URL is updated after second redirect with UrlUpda鈥
鈥eStrategy="eager"

Navigating to a route such as `/users`, you may get redirected to `/login`. Previously, if you go then route to `/users` again the URL will end up showing `/users` after the second redirect. This only happened in `UrlUpdateStrategy="eager"`. This is now fixed so after the second redirect, the URL shows the correct page.

Fixes angular#27116

@mhevery mhevery closed this in ad26cd6 Dec 13, 2018

jasonaden added a commit to jasonaden/angular that referenced this issue Dec 14, 2018

fix(router): ensure URL is updated after second redirect with UrlUpda鈥
鈥eStrategy="eager"

Navigating to a route such as `/users`, you may get redirected to `/login`. Previously, if you go then route to `/users` again the URL will end up showing `/users` after the second redirect. This only happened in `UrlUpdateStrategy="eager"`. This is now fixed so after the second redirect, the URL shows the correct page.

Fixes angular#27116

matsko added a commit that referenced this issue Dec 20, 2018

fix(router): ensure URL is updated after second redirect with UrlUpda鈥
鈥eStrategy="eager" (#27523)

Navigating to a route such as `/users`, you may get redirected to `/login`. Previously, if you go then route to `/users` again the URL will end up showing `/users` after the second redirect. This only happened in `UrlUpdateStrategy="eager"`. This is now fixed so after the second redirect, the URL shows the correct page.

Fixes #27116

PR Close #27523

jasonaden added a commit to jasonaden/angular that referenced this issue Dec 20, 2018

fix(router): ensure URL is updated after second redirect with UrlUpda鈥
鈥eStrategy="eager"

Navigating to a route such as `/users`, you may get redirected to `/login`. Previously, if you go then route to `/users` again the URL will end up showing `/users` after the second redirect. This only happened in `UrlUpdateStrategy="eager"`. This is now fixed so after the second redirect, the URL shows the correct page.

Fixes angular#27116

jasonaden added a commit to jasonaden/angular that referenced this issue Dec 21, 2018

fix(router): ensure URL is updated after second redirect with UrlUpda鈥
鈥eStrategy="eager"

Navigating to a route such as `/users`, you may get redirected to `/login`. Previously, if you go then route to `/users` again the URL will end up showing `/users` after the second redirect. This only happened in `UrlUpdateStrategy="eager"`. This is now fixed so after the second redirect, the URL shows the correct page.

Fixes angular#27116

AndrewKushnir added a commit that referenced this issue Jan 15, 2019

fix(router): ensure URL is updated after second redirect with UrlUpda鈥
鈥eStrategy="eager" (#27680)

Navigating to a route such as `/users`, you may get redirected to `/login`. Previously, if you go then route to `/users` again the URL will end up showing `/users` after the second redirect. This only happened in `UrlUpdateStrategy="eager"`. This is now fixed so after the second redirect, the URL shows the correct page.

Fixes #27116

PR Close #27680

AndrewKushnir added a commit that referenced this issue Jan 16, 2019

fix(router): ensure URL is updated after second redirect with UrlUpda鈥
鈥eStrategy="eager" (#27680)

Navigating to a route such as `/users`, you may get redirected to `/login`. Previously, if you go then route to `/users` again the URL will end up showing `/users` after the second redirect. This only happened in `UrlUpdateStrategy="eager"`. This is now fixed so after the second redirect, the URL shows the correct page.

Fixes #27116

PR Close #27680

ngfelixl added a commit to ngfelixl/angular that referenced this issue Jan 28, 2019

fix(router): ensure URL is updated after second redirect with UrlUpda鈥
鈥eStrategy="eager" (angular#27523)

Navigating to a route such as `/users`, you may get redirected to `/login`. Previously, if you go then route to `/users` again the URL will end up showing `/users` after the second redirect. This only happened in `UrlUpdateStrategy="eager"`. This is now fixed so after the second redirect, the URL shows the correct page.

Fixes angular#27116

PR Close angular#27523

ngfelixl added a commit to ngfelixl/angular that referenced this issue Jan 28, 2019

fix(router): ensure URL is updated after second redirect with UrlUpda鈥
鈥eStrategy="eager" (angular#27523)

Navigating to a route such as `/users`, you may get redirected to `/login`. Previously, if you go then route to `/users` again the URL will end up showing `/users` after the second redirect. This only happened in `UrlUpdateStrategy="eager"`. This is now fixed so after the second redirect, the URL shows the correct page.

Fixes angular#27116

PR Close angular#27523
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can鈥檛 perform that action at this time.
You signed in with another tab or window. Reload to refresh your session. You signed out in another tab or window. Reload to refresh your session.