79463132

Date: 2025-02-24 10:14:44
Score: 1
Natty:
Report link

Yes, In React router v6.4 and above, the previous page is mounted untill the new page is loaded

for unmounting the previous page immediatly when routed to another page, you have to add a key of the new route location to force unmount

 const location = useLocation();
      <Outlet key={location.key} />
Reasons:
  • Low length (0.5):
  • Has code block (-0.5):
  • Low reputation (1):
Posted by: Athul Krishnan