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
// Notice: Since this is never called from any other place than one higher in this file(when writing this...), we could just retrieve the path and find a match by using this.getRouteMatch() [NL]
323
322
// Find the corresponding route.
324
323
constmatch=matchRoutes(this._routes,path);
@@ -336,7 +335,6 @@ export class RouterSlot<D = any, P = any> extends HTMLElement implements IRouter
336
335
// Only change route if its a new route.
337
336
constnavigate=shouldNavigate(this.match,match);
338
337
if(navigate){
339
-
340
338
// If another navigation is still begin resolved in this very moment, then we need to cancel that so it does not end up overriding this new navigation.[NL]
341
339
this._cancelNavigation?.();
342
340
// Listen for another push state event. If another push state event happens
@@ -412,7 +410,7 @@ export class RouterSlot<D = any, P = any> extends HTMLElement implements IRouter
412
410
// We have some routes that share the same component instance, those should not be removed and re-appended [NL]
413
411
constisTheSameComponent=this.firstChild===page;
414
412
415
-
if(!isTheSameComponent){
413
+
if(!isTheSameComponent){
416
414
// Remove the old page by clearing the slot
417
415
this.clearChildren();
418
416
}
@@ -421,7 +419,7 @@ export class RouterSlot<D = any, P = any> extends HTMLElement implements IRouter
421
419
// We do this to ensure that we can find the match in the connectedCallback of the page.
0 commit comments