react-router 7.7.1-pre.0 → 7.7.1
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 +6 -1
- package/dist/development/{chunk-FSG5FGWQ.mjs → chunk-C37GKA54.mjs} +2 -2
- package/dist/development/{chunk-4DODSFAK.js → chunk-K7YFBME3.js} +1 -1
- package/dist/{production/chunk-MZVTKUZ4.mjs → development/chunk-KIUJAIYX.mjs} +2 -2
- package/dist/{production/chunk-PVPY6FX7.js → development/chunk-R73PQUJU.js} +130 -130
- package/dist/development/dom-export.js +3 -3
- package/dist/development/dom-export.mjs +3 -3
- package/dist/development/index-react-server-client.js +4 -4
- package/dist/development/index-react-server-client.mjs +2 -2
- package/dist/development/index-react-server.js +1 -1
- package/dist/development/index-react-server.mjs +1 -1
- package/dist/development/index.js +97 -97
- package/dist/development/index.mjs +3 -3
- package/dist/development/lib/types/internal.js +1 -1
- package/dist/development/lib/types/internal.mjs +1 -1
- package/dist/{development/chunk-JKVEU2V7.js → production/chunk-4DGLNKXF.js} +130 -130
- package/dist/production/{chunk-BPUKNCMM.js → chunk-7OQROU2D.js} +1 -1
- package/dist/production/{chunk-J4LDCI7O.mjs → chunk-IZ57JD2V.mjs} +2 -2
- package/dist/{development/chunk-KFHXRAUZ.mjs → production/chunk-K3SBCRK4.mjs} +2 -2
- package/dist/production/dom-export.js +3 -3
- package/dist/production/dom-export.mjs +3 -3
- package/dist/production/index-react-server-client.js +4 -4
- package/dist/production/index-react-server-client.mjs +2 -2
- package/dist/production/index-react-server.js +1 -1
- package/dist/production/index-react-server.mjs +1 -1
- package/dist/production/index.js +97 -97
- package/dist/production/index.mjs +3 -3
- package/dist/production/lib/types/internal.js +1 -1
- package/dist/production/lib/types/internal.mjs +1 -1
- package/package.json +1 -1
package/CHANGELOG.md
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
# `react-router`
|
|
2
2
|
|
|
3
|
-
## 7.7.1
|
|
3
|
+
## 7.7.1
|
|
4
4
|
|
|
5
5
|
### Patch Changes
|
|
6
6
|
|
|
@@ -604,6 +604,7 @@
|
|
|
604
604
|
```
|
|
605
605
|
|
|
606
606
|
Similar to server-side requests, a fresh `context` will be created per navigation (or `fetcher` call). If you have initial data you'd like to populate in the context for every request, you can provide an `unstable_getContext` function at the root of your app:
|
|
607
|
+
|
|
607
608
|
- Library mode - `createBrowserRouter(routes, { unstable_getContext })`
|
|
608
609
|
- Framework mode - `<HydratedRouter unstable_getContext>`
|
|
609
610
|
|
|
@@ -791,6 +792,7 @@ _No changes_
|
|
|
791
792
|
- Remove `future.v7_normalizeFormMethod` future flag ([#11697](https://github.com/remix-run/react-router/pull/11697))
|
|
792
793
|
|
|
793
794
|
- For Remix consumers migrating to React Router, the `crypto` global from the [Web Crypto API](https://developer.mozilla.org/en-US/docs/Web/API/Web_Crypto_API) is now required when using cookie and session APIs. This means that the following APIs are provided from `react-router` rather than platform-specific packages: ([#11837](https://github.com/remix-run/react-router/pull/11837))
|
|
795
|
+
|
|
794
796
|
- `createCookie`
|
|
795
797
|
- `createCookieSessionStorage`
|
|
796
798
|
- `createMemorySessionStorage`
|
|
@@ -799,6 +801,7 @@ _No changes_
|
|
|
799
801
|
For consumers running older versions of Node, the `installGlobals` function from `@remix-run/node` has been updated to define `globalThis.crypto`, using [Node's `require('node:crypto').webcrypto` implementation.](https://nodejs.org/api/webcrypto.html)
|
|
800
802
|
|
|
801
803
|
Since platform-specific packages no longer need to implement this API, the following low-level APIs have been removed:
|
|
804
|
+
|
|
802
805
|
- `createCookieFactory`
|
|
803
806
|
- `createSessionStorageFactory`
|
|
804
807
|
- `createCookieSessionStorageFactory`
|
|
@@ -954,6 +957,7 @@ _No changes_
|
|
|
954
957
|
```
|
|
955
958
|
|
|
956
959
|
This initial implementation targets type inference for:
|
|
960
|
+
|
|
957
961
|
- `Params` : Path parameters from your routing config in `routes.ts` including file-based routing
|
|
958
962
|
- `LoaderData` : Loader data from `loader` and/or `clientLoader` within your route module
|
|
959
963
|
- `ActionData` : Action data from `action` and/or `clientAction` within your route module
|
|
@@ -968,6 +972,7 @@ _No changes_
|
|
|
968
972
|
```
|
|
969
973
|
|
|
970
974
|
Check out our docs for more:
|
|
975
|
+
|
|
971
976
|
- [_Explanations > Type Safety_](https://reactrouter.com/dev/guides/explanation/type-safety)
|
|
972
977
|
- [_How-To > Setting up type safety_](https://reactrouter.com/dev/guides/how-to/setting-up-type-safety)
|
|
973
978
|
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* react-router v7.7.1
|
|
2
|
+
* react-router v7.7.1
|
|
3
3
|
*
|
|
4
4
|
* Copyright (c) Remix Software Inc.
|
|
5
5
|
*
|
|
@@ -8845,7 +8845,7 @@ var isBrowser = typeof window !== "undefined" && typeof window.document !== "und
|
|
|
8845
8845
|
try {
|
|
8846
8846
|
if (isBrowser) {
|
|
8847
8847
|
window.__reactRouterVersion = // @ts-expect-error
|
|
8848
|
-
"7.7.1
|
|
8848
|
+
"7.7.1";
|
|
8849
8849
|
}
|
|
8850
8850
|
} catch (e) {
|
|
8851
8851
|
}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
"use strict";Object.defineProperty(exports, "__esModule", {value: true}); function _interopRequireWildcard(obj) { if (obj && obj.__esModule) { return obj; } else { var newObj = {}; if (obj != null) { for (var key in obj) { if (Object.prototype.hasOwnProperty.call(obj, key)) { newObj[key] = obj[key]; } } } newObj.default = obj; return newObj; } } function _nullishCoalesce(lhs, rhsFn) { if (lhs != null) { return lhs; } else { return rhsFn(); } } function _optionalChain(ops) { let lastAccessLHS = undefined; let value = ops[0]; let i = 1; while (i < ops.length) { const op = ops[i]; const fn = ops[i + 1]; i += 2; if ((op === 'optionalAccess' || op === 'optionalCall') && value == null) { return undefined; } if (op === 'access' || op === 'optionalAccess') { lastAccessLHS = value; value = fn(value); } else if (op === 'call' || op === 'optionalCall') { value = fn((...args) => value.call(lastAccessLHS, ...args)); lastAccessLHS = undefined; } } return value; }/**
|
|
2
|
-
* react-router v7.7.1
|
|
2
|
+
* react-router v7.7.1
|
|
3
3
|
*
|
|
4
4
|
* Copyright (c) Remix Software Inc.
|
|
5
5
|
*
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* react-router v7.7.1
|
|
2
|
+
* react-router v7.7.1
|
|
3
3
|
*
|
|
4
4
|
* Copyright (c) Remix Software Inc.
|
|
5
5
|
*
|
|
@@ -57,7 +57,7 @@ import {
|
|
|
57
57
|
withComponentProps,
|
|
58
58
|
withErrorBoundaryProps,
|
|
59
59
|
withHydrateFallbackProps
|
|
60
|
-
} from "./chunk-
|
|
60
|
+
} from "./chunk-C37GKA54.mjs";
|
|
61
61
|
|
|
62
62
|
// lib/dom/ssr/server.tsx
|
|
63
63
|
import * as React from "react";
|