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

Since last update Suspense with RouterView acting weird #9769

Closed
1337huania opened this issue Dec 7, 2023 · 2 comments · Fixed by #9770
Closed

Since last update Suspense with RouterView acting weird #9769

1337huania opened this issue Dec 7, 2023 · 2 comments · Fixed by #9770
Labels
🐞 bug Something isn't working scope: suspense

Comments

@1337huania
Copy link

1337huania commented Dec 7, 2023

Vue version

3.3.10

Link to minimal reproduction

https://codesandbox.io/p/devbox/upbeat-ully-64czlg?file=%2Fsrc%2FApp.vue%3A10%2C35

Steps to reproduce

Navigate between ViewA and ViewB.

What is expected?

HTML elements suppose to keep same order (Navigation, RouterView, Footer) after navigating between views.

What is actually happening?

HTML elements being rendered in wrong order (Navigation, Footer, RouterView) after navigating between sync (ViewA) and async (ViewB) views.

System Info

No response

Any additional comments?

Ran into an issue after updating Vue to 3.3.10. Looks like it's related related to latest (3.3.10) release changes (#8105) and is most likely not related to Vue Router itself, but rather to async components.

— Issue persists even if I toggling between components programatically, without RouterView.
— Removing timeout property from Suspense gives weird delay but footer stays in place.
— Wrapping Suspense in to div makes Footer to stay in correct order.

@1337huania 1337huania changed the title Since last update Suspense with RouterView Since last update Suspense with RouterView acting weird Dec 7, 2023
@yyx990803
Copy link
Member

Most likely related to #9309

/cc @edison1105

@edison1105
Copy link
Member

@1337huania

Removing timeout property from Suspense gives weird delay but footer stays in place.

This is expected behavior. see https://vuejs.org/guide/built-ins/suspense.html#loading-state

@github-actions github-actions bot locked and limited conversation to collaborators Dec 23, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
🐞 bug Something isn't working scope: suspense
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants