react-router 0.0.0-experimental-178bc9ee → 0.0.0-experimental-4841e12b
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/dist/index.js +9 -4
- package/dist/index.js.map +1 -1
- package/dist/main.js +1 -1
- package/dist/react-router.development.js +8 -4
- 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 +9 -4
- 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 +2 -2
package/dist/index.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* React Router v0.0.0-experimental-
|
|
2
|
+
* React Router v0.0.0-experimental-4841e12b
|
|
3
3
|
*
|
|
4
4
|
* Copyright (c) Remix Software Inc.
|
|
5
5
|
*
|
|
@@ -548,9 +548,14 @@ function _renderMatches(matches, parentMatches, dataRouterState, future) {
|
|
|
548
548
|
if (match.route.Fallback || match.route.fallbackElement) {
|
|
549
549
|
fallbackIndex = i;
|
|
550
550
|
}
|
|
551
|
-
if (match.route.loader && match.route.id && dataRouterState.loaderData[match.route.id] === undefined) {
|
|
552
|
-
//
|
|
553
|
-
//
|
|
551
|
+
if (match.route.loader && match.route.id && dataRouterState.loaderData[match.route.id] === undefined && (!dataRouterState.errors || dataRouterState.errors[match.route.id] === undefined)) {
|
|
552
|
+
// TODO:
|
|
553
|
+
// TODO: Add unit tests for this error flow!
|
|
554
|
+
// TODO:
|
|
555
|
+
|
|
556
|
+
// We found the first route without data/errors which means it's loader
|
|
557
|
+
// still needs to run. Flag that we need to render a fallback and
|
|
558
|
+
// render up until the appropriate fallback
|
|
554
559
|
renderFallback = true;
|
|
555
560
|
if (fallbackIndex >= 0) {
|
|
556
561
|
renderedMatches = renderedMatches.slice(0, fallbackIndex + 1);
|