react-router 7.9.2-pre.3 → 7.9.3-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.
Files changed (30) hide show
  1. package/CHANGELOG.md +15 -8
  2. package/dist/{production/chunk-W5PNW5ME.mjs → development/chunk-HHJJZWWP.mjs} +6 -10
  3. package/dist/{production/chunk-NQKLZ2ZX.js → development/chunk-MREZ7GBS.js} +134 -134
  4. package/dist/development/{chunk-665FWGER.js → chunk-OUSD3CXG.js} +7 -4
  5. package/dist/development/{chunk-2WPYM2VW.mjs → chunk-TZREDCP7.mjs} +8 -5
  6. package/dist/development/dom-export.js +3 -3
  7. package/dist/development/dom-export.mjs +3 -3
  8. package/dist/development/index-react-server-client.js +4 -4
  9. package/dist/development/index-react-server-client.mjs +2 -2
  10. package/dist/development/index-react-server.js +5 -2
  11. package/dist/development/index-react-server.mjs +5 -2
  12. package/dist/development/index.js +100 -104
  13. package/dist/development/index.mjs +3 -3
  14. package/dist/development/lib/types/internal.js +1 -1
  15. package/dist/development/lib/types/internal.mjs +1 -1
  16. package/dist/production/{chunk-ADN7TWEK.js → chunk-AR4BV4G2.js} +7 -4
  17. package/dist/production/{chunk-R53WSUO7.mjs → chunk-RX77WZIY.mjs} +8 -5
  18. package/dist/{development/chunk-QWBW4WZW.js → production/chunk-YE2RU2Y2.js} +134 -134
  19. package/dist/{development/chunk-AQYUIXYF.mjs → production/chunk-ZS4K3BVQ.mjs} +6 -10
  20. package/dist/production/dom-export.js +3 -3
  21. package/dist/production/dom-export.mjs +3 -3
  22. package/dist/production/index-react-server-client.js +4 -4
  23. package/dist/production/index-react-server-client.mjs +2 -2
  24. package/dist/production/index-react-server.js +5 -2
  25. package/dist/production/index-react-server.mjs +5 -2
  26. package/dist/production/index.js +100 -104
  27. package/dist/production/index.mjs +3 -3
  28. package/dist/production/lib/types/internal.js +1 -1
  29. package/dist/production/lib/types/internal.mjs +1 -1
  30. package/package.json +1 -1
package/CHANGELOG.md CHANGED
@@ -1,31 +1,38 @@
1
1
  # `react-router`
2
2
 
3
- ## 7.9.2-pre.3
4
-
5
- ## 7.9.2-pre.2
6
-
7
- ## 7.9.2-pre.1
3
+ ## 7.9.3-pre.0
8
4
 
9
5
  ### Patch Changes
10
6
 
11
- - feat: enable full transition support for the rsc router ([#14362](https://github.com/remix-run/react-router/pull/14362))
7
+ - Do not try to use `turbo-stream` to decode CDN errors that never reached the server ([#14385](https://github.com/remix-run/react-router/pull/14385))
8
+ - We used to do this but lost this check with the adoption of single fetch
12
9
 
13
- ## 7.9.2-pre.0
10
+ - Fix Data Mode regression causing a 404 during initial load in when `middleware` exists without any `loader` functions ([#14393](https://github.com/remix-run/react-router/pull/14393))
11
+
12
+ ## 7.9.2
14
13
 
15
14
  ### Patch Changes
16
15
 
17
16
  - - Update client-side router to run client `middleware` on initial load even if no loaders exist ([#14348](https://github.com/remix-run/react-router/pull/14348))
18
17
  - Update `createRoutesStub` to run route middleware
19
18
  - You will need to set the `<RoutesStub future={{ v8_middleware: true }} />` flag to enable the proper `context` type
19
+
20
20
  - Update Lazy Route Discovery manifest requests to use a singular comma-separated `paths` query param instead of repeated `p` query params ([#14321](https://github.com/remix-run/react-router/pull/14321))
21
21
  - This is because Cloudflare has a hard limit of 100 URL search param key/value pairs when used as a key for caching purposes
22
22
  - If more that 100 paths were included, the cache key would be incomplete and could produce false-positive cache hits
23
23
 
24
- - [UNSTABLE] Add `fetcher.unstable_reset()` API ([#14206](https://github.com/remix-run/react-router/pull/14206))
24
+ - \[UNSTABLE] Add `fetcher.unstable_reset()` API ([#14206](https://github.com/remix-run/react-router/pull/14206))
25
+
25
26
  - Made useOutlet element reference have stable identity in-between route chages ([#13382](https://github.com/remix-run/react-router/pull/13382))
27
+
28
+ - feat: enable full transition support for the rsc router ([#14362](https://github.com/remix-run/react-router/pull/14362))
29
+
26
30
  - In RSC Data Mode, handle SSR'd client errors and re-try in the browser ([#14342](https://github.com/remix-run/react-router/pull/14342))
31
+
27
32
  - Support `middleware` prop on `<Route>` for usage with a data router via `createRoutesFromElements` ([#14357](https://github.com/remix-run/react-router/pull/14357))
33
+
28
34
  - Handle encoded question mark and hash characters in ancestor splat routes ([#14249](https://github.com/remix-run/react-router/pull/14249))
35
+
29
36
  - Fail gracefully on manifest version mismatch logic if `sessionStorage` access is blocked ([#14335](https://github.com/remix-run/react-router/pull/14335))
30
37
 
31
38
  ## 7.9.1
@@ -1,5 +1,5 @@
1
1
  /**
2
- * react-router v7.9.2-pre.3
2
+ * react-router v7.9.3-pre.0
3
3
  *
4
4
  * Copyright (c) Remix Software Inc.
5
5
  *
@@ -60,7 +60,7 @@ import {
60
60
  withComponentProps,
61
61
  withErrorBoundaryProps,
62
62
  withHydrateFallbackProps
63
- } from "./chunk-R53WSUO7.mjs";
63
+ } from "./chunk-TZREDCP7.mjs";
64
64
 
65
65
  // lib/dom/ssr/server.tsx
66
66
  import * as React from "react";
@@ -1459,7 +1459,6 @@ async function handleResourceRequest(serverMode, build, staticHandler, routeId,
1459
1459
  }
1460
1460
  function handleQueryRouteError(error) {
1461
1461
  if (isResponse(error)) {
1462
- error.headers.set("X-Remix-Catch", "yes");
1463
1462
  return error;
1464
1463
  }
1465
1464
  if (isRouteErrorResponse(error)) {
@@ -1486,10 +1485,7 @@ function errorResponseToJson(errorResponse, serverMode) {
1486
1485
  ),
1487
1486
  {
1488
1487
  status: errorResponse.status,
1489
- statusText: errorResponse.statusText,
1490
- headers: {
1491
- "X-Remix-Error": "yes"
1492
- }
1488
+ statusText: errorResponse.statusText
1493
1489
  }
1494
1490
  );
1495
1491
  }
@@ -2160,8 +2156,8 @@ function getFetchAndDecodeViaRSC(createFromReadableStream, fetchImplementation)
2160
2156
  let res = await fetchImplementation(
2161
2157
  new Request(url, await createRequestInit(request))
2162
2158
  );
2163
- if (res.status === 404 && !res.headers.has("X-Remix-Response")) {
2164
- throw new ErrorResponseImpl(404, "Not Found", true);
2159
+ if (res.status >= 400 && !res.headers.has("X-Remix-Response")) {
2160
+ throw new ErrorResponseImpl(res.status, res.statusText, await res.text());
2165
2161
  }
2166
2162
  invariant(res.body, "No response body to decode");
2167
2163
  try {
@@ -2649,7 +2645,7 @@ async function routeRSCServerRequest({
2649
2645
  headers2.delete("Content-Encoding");
2650
2646
  headers2.delete("Content-Length");
2651
2647
  headers2.delete("Content-Type");
2652
- headers2.delete("x-remix-response");
2648
+ headers2.delete("X-Remix-Response");
2653
2649
  headers2.set("Location", payload.location);
2654
2650
  return new Response(serverResponseB?.body || "", {
2655
2651
  headers: headers2,