You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
RouterOutlet loads component 2x in a race condition #7497
RouterOutlet#reuse checks if there is no current _componentRef and in that case creates a new component.
However, _componentRef is not set until the call to DynamicComponentLoader.loadNextToLocation is finished (in RouterOutlet#activate). If that call takes a bit longer (e.g. loading an html file from the server) RouterOutlet will create 2 instances of the component.
On my branch for codegen templates that changes the timing of DynamicComponentLoading a bit, the test for syncRoutesWithDynamicComponents (in sync_route_spec_impl.ts) fails because of this.
@mhevery can you figure out who should work on this one? It seems to be related to #7318. Tests for the codegen branch are failing because of this issue.
Activity
tbosch commentedon Mar 9, 2016
Setting to P1 as the issue the commit that introduced this logic was marked as P0... (#7318)
naomiblack commentedon Mar 10, 2016
@mhevery can you figure out who should work on this one? It seems to be related to #7318. Tests for the codegen branch are failing because of this issue.
angular-automatic-lock-bot commentedon Sep 8, 2019
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.