-
Notifications
You must be signed in to change notification settings - Fork 25.7k
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(router): bootstrap finishes before all routes are resolved #12162
Comments
Notes: Currently we trigger the initial navigation in a bootstrap listener. Angular does not wait for bootstrap listeners to complete.Moving the logic naively into an application listener will not work because the root component is not created at that point. So the router can successfully run |
Is this being address by anyone? More than 3 months and it's still happening :/ |
…solved (4x) (angular#14155) Fixes angular#12162 PR Close angular#14155
…solved (4x) (angular#14155) Fixes angular#12162 PR Close angular#14155
@vicb the fix was merged so it can be closed |
This issue has been automatically locked due to inactivity. Read more about our automatic conversation locking policy. This action has been performed automatically by a bot. |
I'm submitting a ... (check one with "x")
Current behavior
If I have a router that requires resolving async data, bootstrap will complete before the router has finished resolving and rendering. Any parent components that have already loaded will be rendered while waiting for children to load. This behavior is most problematic with pre-rendered applications. The user will first see the pre-rendered content, then when bootstrap is complete and route resolution is still pending, they'll see either a blank page or partially-rendered page, then once all routes are resolved, the full page content will render and should match the pre-rendered content .
Expected behavior
I expect
bootstrap
not to complete before route resolution and rendering is complete.Minimal reproduction of the problem with instructions
npm run start
https://github.com/jeffbcross/cli-aot-route-bugWhat is the motivation / use case for changing the behavior?
A smooth transition from pre-rendered page to dynamic page and preboot compatibility.
The text was updated successfully, but these errors were encountered: