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

fix(angular1_router): delay view update until activate promise gets fullfilled #7777

Closed

Conversation

Mischi
Copy link
Contributor

@Mischi Mischi commented Mar 26, 2016

  • What kind of change does this PR introduce? (Bug fix, feature, docs update, ...)
    Bug fix
  • What is the current behavior?
    If the $routerOnActivate hook returns a promise, the navigation
    is commited once the promise gets fullfilled but the view
    is updated immediately.
    View and url are not synchron until the promise gets fullfilled.
  • What is the new behavior (if this is a feature change)?
    This PR delays the view update so that both (view and url) are
    updated at the same time.
    This is the expected behaviour if i understand the docs correct.
  • Does this PR introduce a breaking change? (What changes might users need to make in their application due to this PR?)
    No breaking changes intended.

CC: @davidreher

…ullfilled

If the $routerOnActivate hook returns a promise, the navigation
is commited, once the promise gets fullfilled but the view
is updated immediately.

This commit delays the view update so that both (view and url) are
updated at the same time.
@Mischi Mischi force-pushed the fix-onActivate-view-update branch from 7c52e19 to b3a9e20 Compare March 26, 2016 10:22
@Mischi
Copy link
Contributor Author

Mischi commented Apr 26, 2016

@petebacondarwin what do you think?

@petebacondarwin
Copy link
Member

This looks like it is doing the right thing. I will review it in detail later this week.

@petebacondarwin petebacondarwin self-assigned this Apr 26, 2016
@mhevery mhevery closed this in 90af476 May 20, 2016
KiaraGrouwstra pushed a commit to KiaraGrouwstra/angular that referenced this pull request Jun 10, 2016
…ullfilled

If the $routerOnActivate hook returns a promise, the navigation
is commited, once the promise gets fullfilled but the view
is updated immediately.

This commit delays the view update so that both (view and url) are
updated at the same time.

Closes angular#7777
@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 Sep 8, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants