@tanstack/react-router 1.84.0 → 1.84.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -620,7 +620,8 @@ class Router {
620
620
  try {
621
621
  const next = this.latestLocation;
622
622
  const prevLocation = this.state.resolvedLocation;
623
- const pathDidChange = prevLocation.href !== next.href;
623
+ const hrefChanged = prevLocation.href !== next.href;
624
+ const pathChanged = prevLocation.pathname !== next.pathname;
624
625
  this.cancelMatches();
625
626
  let pendingMatches;
626
627
  this.__store.batch(() => {
@@ -642,14 +643,16 @@ class Router {
642
643
  type: "onBeforeNavigate",
643
644
  fromLocation: prevLocation,
644
645
  toLocation: next,
645
- pathChanged: pathDidChange
646
+ pathChanged,
647
+ hrefChanged
646
648
  });
647
649
  }
648
650
  this.emit({
649
651
  type: "onBeforeLoad",
650
652
  fromLocation: prevLocation,
651
653
  toLocation: next,
652
- pathChanged: pathDidChange
654
+ pathChanged,
655
+ hrefChanged
653
656
  });
654
657
  await this.loadMatches({
655
658
  matches: pendingMatches,