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

Handling Loading State for async route components. #2445

Closed
abdallanayer opened this issue Oct 22, 2018 · 6 comments
Closed

Handling Loading State for async route components. #2445

abdallanayer opened this issue Oct 22, 2018 · 6 comments

Comments

@abdallanayer
Copy link

Version

3.0.1

Reproduction link

https://codesandbox.io/s/8xn8jn4xl9

Steps to reproduce

Click on Foo and check the network tab and console

What is expected?

Based on what is mentioned in the documentation
https://vuejs.org/v2/guide/components-dynamic-async.html#Handling-Loading-State
That this should work as well for async route components since 2.4.0

What is actually happening?

It is not working on async route components but working well on async components

@posva
Copy link
Member

posva commented Oct 22, 2018

It seems to be working on my end. You will have to provide more information about what not working means 😄

@posva posva closed this as completed Oct 22, 2018
@abdallanayer
Copy link
Author

my bad 👍 what i mean is the route is successfully loaded but the Loading.vue component is not even mounted, I expected to see "I WAS HERE" in the console and it didnot happen. This is not the case when using the same syntax with async components not routes, I can see "I WAS HERE" in the console in that case, hope I explained the problem more, thank you

@posva
Copy link
Member

posva commented Oct 22, 2018

Have you seen #2140 ?

@abdallanayer
Copy link
Author

Thank you Posva this helps, but why this pull request is not merged ? will this be changed ? is it not advised to use this ?

@posva
Copy link
Member

posva commented Oct 23, 2018 via email

@ustbhuangyi
Copy link

Also need this feature, hoped it been merged

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

No branches or pull requests

3 participants