react-router 6.22.3 → 6.23.0-pre.0
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.
- package/CHANGELOG.md +14 -0
- package/dist/index.d.ts +3 -2
- package/dist/index.js +4 -3
- package/dist/index.js.map +1 -1
- package/dist/main.js +1 -1
- package/dist/react-router.development.js +4 -3
- package/dist/react-router.development.js.map +1 -1
- package/dist/react-router.production.min.js +2 -2
- package/dist/react-router.production.min.js.map +1 -1
- package/dist/umd/react-router.development.js +4 -3
- package/dist/umd/react-router.development.js.map +1 -1
- package/dist/umd/react-router.production.min.js +2 -2
- package/dist/umd/react-router.production.min.js.map +1 -1
- package/package.json +5 -4
package/dist/main.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* React Router v6.
|
|
2
|
+
* React Router v6.23.0-pre.0
|
|
3
3
|
*
|
|
4
4
|
* Copyright (c) Remix Software Inc.
|
|
5
5
|
*
|
|
@@ -491,7 +491,7 @@ function _renderMatches(matches, parentMatches = [], dataRouterState = null, fut
|
|
|
491
491
|
// If we have data errors, trim matches to the highest error boundary
|
|
492
492
|
let errors = dataRouterState?.errors;
|
|
493
493
|
if (errors != null) {
|
|
494
|
-
let errorIndex = renderedMatches.findIndex(m => m.route.id && errors?.[m.route.id]);
|
|
494
|
+
let errorIndex = renderedMatches.findIndex(m => m.route.id && errors?.[m.route.id] !== undefined);
|
|
495
495
|
!(errorIndex >= 0) ? UNSAFE_invariant(false, `Could not find a matching route for errors on route IDs: ${Object.keys(errors).join(",")}`) : void 0;
|
|
496
496
|
renderedMatches = renderedMatches.slice(0, Math.min(renderedMatches.length, errorIndex + 1));
|
|
497
497
|
}
|
|
@@ -1342,7 +1342,8 @@ function createMemoryRouter(routes, opts) {
|
|
|
1342
1342
|
}),
|
|
1343
1343
|
hydrationData: opts?.hydrationData,
|
|
1344
1344
|
routes,
|
|
1345
|
-
mapRouteProperties
|
|
1345
|
+
mapRouteProperties,
|
|
1346
|
+
unstable_dataStrategy: opts?.unstable_dataStrategy
|
|
1346
1347
|
}).initialize();
|
|
1347
1348
|
}
|
|
1348
1349
|
|