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

router back not work when loading #3150

Closed
snowtreetree opened this issue Mar 20, 2020 · 3 comments
Closed

router back not work when loading #3150

snowtreetree opened this issue Mar 20, 2020 · 3 comments

Comments

@snowtreetree
Copy link

@snowtreetree snowtreetree commented Mar 20, 2020

Version

3.1.6

Reproduction link

https://github.com/snowtreetree/router-back

Steps to reproduce

image

What is expected?

router back immediately.

What is actually happening?

when something is loading,i want to let router go back, but the page does not change immediately, when browser loading end, the page show correctly.


In my app , I need to do something in router change(log my page path, title), but when the internet speed is slow, use the function of back or go(-1), I can not back 🤷‍♀️

@posva

This comment has been minimized.

Copy link
Member

@posva posva commented Mar 20, 2020

when something is loading,i want to let router go back, but the page does not change immediately, when browser loading end, the page show correctly.

The Router needs to wait for the js that is necessary to render your page before navigating there. This needs to happen with both normal navigation and history-based navigation (back and forward buttons)

Note: please, next time, provide explicit written steps in reproductions steps, not a screenshot, it will be much clearer

@posva posva closed this Mar 20, 2020
@snowtreetree

This comment has been minimized.

Copy link
Author

@snowtreetree snowtreetree commented Mar 21, 2020

but why forward is ok? @posva , in app, you can change network to slow3g,when browser top left show loading, click to button, the page show correctly, then click browser back, the router params have changed, but the page show no change.

@snowtreetree

This comment has been minimized.

Copy link
Author

@snowtreetree snowtreetree commented Mar 22, 2020

https://www.youtube.com/watch?v=dxpUgt-fCSo
@posva I upload my video to youtube , you can watch it.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Linked pull requests

Successfully merging a pull request may close this issue.

None yet
2 participants
You can’t perform that action at this time.