@@ -71,7 +71,6 @@ export class StackManager extends React.PureComponent<StackManagerProps> {
7171 isInOutlet : ( ) => true ,
7272 } ;
7373
74- private clearOutletTimeout : any ;
7574 private pendingPageTransition = false ;
7675 private waitingForIonPage = false ;
7776 private ionPageWaitTimeout ?: ReturnType < typeof setTimeout > ;
@@ -756,18 +755,6 @@ export class StackManager extends React.PureComponent<StackManagerProps> {
756755
757756 componentDidMount ( ) {
758757 this . _isMounted = true ;
759- if ( this . clearOutletTimeout ) {
760- /**
761- * The clearOutlet integration with React Router is a bit hacky.
762- * It uses a timeout to clear the outlet after a transition.
763- * In React v18, components are mounted and unmounted in development mode
764- * to check for side effects.
765- *
766- * This clearTimeout prevents the outlet from being cleared when the component is re-mounted,
767- * which should only happen in development mode and as a result of a hot reload.
768- */
769- clearTimeout ( this . clearOutletTimeout ) ;
770- }
771758 if ( this . routerOutletElement ) {
772759 this . setupRouterOutlet ( this . routerOutletElement ) ;
773760 this . handlePageTransition ( this . props . routeInfo ) ;
@@ -822,7 +809,7 @@ export class StackManager extends React.PureComponent<StackManagerProps> {
822809 hideIonPageElement ( viewItem . ionPageElement ) ;
823810 } ) ;
824811
825- this . clearOutletTimeout = this . context . clearOutlet ( this . id ) ;
812+ this . context . clearOutlet ( this . id ) ;
826813 }
827814
828815 /**
0 commit comments