react-router 7.11.0 → 7.12.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.
Files changed (68) hide show
  1. package/CHANGELOG.md +46 -13
  2. package/dist/development/{browser-Cv4JZyZ5.d.mts → browser-BEPxnEBW.d.mts} +4 -2
  3. package/dist/{production/browser-Cv4JZyZ5.d.mts → development/browser-CJ9_du-U.d.ts} +4 -2
  4. package/dist/development/{chunk-YNUBSHFH.mjs → chunk-2RQJSHF5.mjs} +111 -11
  5. package/dist/development/{chunk-2JY4UAJA.js → chunk-AUGQXA25.js} +98 -108
  6. package/dist/{production/chunk-BEXOWXJO.js → development/chunk-JBLDGBX7.js} +7 -7
  7. package/dist/development/{chunk-JMJ3UQ3L.mjs → chunk-KYKH2NCS.mjs} +122 -50
  8. package/dist/development/{chunk-SZQUWNVJ.js → chunk-MNTWZBMV.js} +117 -35
  9. package/dist/development/dom-export.d.mts +2 -2
  10. package/dist/development/dom-export.d.ts +2 -2
  11. package/dist/development/dom-export.js +35 -30
  12. package/dist/development/dom-export.mjs +12 -7
  13. package/dist/development/{index-react-server-client-P7VgYu6T.d.mts → index-react-server-client-IoJGLOqV.d.mts} +3 -1
  14. package/dist/{production/index-react-server-client-Cv5Q9lf0.d.ts → development/index-react-server-client-gGyf-7Xp.d.ts} +3 -1
  15. package/dist/development/index-react-server-client.d.mts +2 -2
  16. package/dist/development/index-react-server-client.d.ts +2 -2
  17. package/dist/development/index-react-server-client.js +4 -4
  18. package/dist/development/index-react-server-client.mjs +2 -2
  19. package/dist/development/index-react-server.d.mts +3 -1
  20. package/dist/development/index-react-server.d.ts +3 -1
  21. package/dist/development/index-react-server.js +92 -7
  22. package/dist/development/index-react-server.mjs +92 -7
  23. package/dist/development/index.d.mts +9 -9
  24. package/dist/development/index.d.ts +9 -9
  25. package/dist/development/index.js +205 -101
  26. package/dist/development/index.mjs +7 -3
  27. package/dist/{production/instrumentation-BlrVzjbg.d.ts → development/instrumentation-DvHY1sgY.d.ts} +45 -1
  28. package/dist/development/lib/types/internal.d.mts +2 -2
  29. package/dist/development/lib/types/internal.d.ts +2 -2
  30. package/dist/development/lib/types/internal.js +1 -1
  31. package/dist/development/lib/types/internal.mjs +1 -1
  32. package/dist/development/{register-BGQUMCK4.d.ts → register-Bm80E9qL.d.ts} +1 -1
  33. package/dist/development/{register-DTJJbt1o.d.mts → register-CS_tiXsm.d.mts} +1 -1
  34. package/dist/development/{router-5fbeEIMQ.d.mts → router-5iOvts3c.d.mts} +45 -1
  35. package/dist/{development/browser-o-qhcuhA.d.ts → production/browser-BEPxnEBW.d.mts} +4 -2
  36. package/dist/production/{browser-o-qhcuhA.d.ts → browser-CJ9_du-U.d.ts} +4 -2
  37. package/dist/production/{chunk-TINMVEA2.mjs → chunk-HFQUWXEK.mjs} +122 -50
  38. package/dist/production/{chunk-E6GYEQUT.mjs → chunk-ILRYJQTC.mjs} +111 -11
  39. package/dist/{development/chunk-GNDLROV6.js → production/chunk-O6YLM5NB.js} +7 -7
  40. package/dist/production/{chunk-ZMYPVUNZ.js → chunk-QWJQISZK.js} +98 -108
  41. package/dist/production/{chunk-2HFJAX7U.js → chunk-ZR2NIBH2.js} +117 -35
  42. package/dist/production/dom-export.d.mts +2 -2
  43. package/dist/production/dom-export.d.ts +2 -2
  44. package/dist/production/dom-export.js +35 -30
  45. package/dist/production/dom-export.mjs +12 -7
  46. package/dist/production/{index-react-server-client-P7VgYu6T.d.mts → index-react-server-client-IoJGLOqV.d.mts} +3 -1
  47. package/dist/{development/index-react-server-client-Cv5Q9lf0.d.ts → production/index-react-server-client-gGyf-7Xp.d.ts} +3 -1
  48. package/dist/production/index-react-server-client.d.mts +2 -2
  49. package/dist/production/index-react-server-client.d.ts +2 -2
  50. package/dist/production/index-react-server-client.js +4 -4
  51. package/dist/production/index-react-server-client.mjs +2 -2
  52. package/dist/production/index-react-server.d.mts +3 -1
  53. package/dist/production/index-react-server.d.ts +3 -1
  54. package/dist/production/index-react-server.js +92 -7
  55. package/dist/production/index-react-server.mjs +92 -7
  56. package/dist/production/index.d.mts +9 -9
  57. package/dist/production/index.d.ts +9 -9
  58. package/dist/production/index.js +205 -101
  59. package/dist/production/index.mjs +7 -3
  60. package/dist/{development/instrumentation-BlrVzjbg.d.ts → production/instrumentation-DvHY1sgY.d.ts} +45 -1
  61. package/dist/production/lib/types/internal.d.mts +2 -2
  62. package/dist/production/lib/types/internal.d.ts +2 -2
  63. package/dist/production/lib/types/internal.js +1 -1
  64. package/dist/production/lib/types/internal.mjs +1 -1
  65. package/dist/production/{register-BGQUMCK4.d.ts → register-Bm80E9qL.d.ts} +1 -1
  66. package/dist/production/{register-DTJJbt1o.d.mts → register-CS_tiXsm.d.mts} +1 -1
  67. package/dist/production/{router-5fbeEIMQ.d.mts → router-5iOvts3c.d.mts} +45 -1
  68. package/package.json +1 -1
@@ -1,5 +1,5 @@
1
1
  /**
2
- * react-router v7.11.0
2
+ * react-router v7.12.0-pre.0
3
3
  *
4
4
  * Copyright (c) Remix Software Inc.
5
5
  *
@@ -28,7 +28,7 @@ import {
28
28
  isSession,
29
29
  routeRSCServerRequest,
30
30
  setDevServerHooks
31
- } from "./chunk-YNUBSHFH.mjs";
31
+ } from "./chunk-2RQJSHF5.mjs";
32
32
  import {
33
33
  Action,
34
34
  Await,
@@ -76,7 +76,9 @@ import {
76
76
  createClientRoutes,
77
77
  createClientRoutesWithHMRRevalidationOptOut,
78
78
  createContext,
79
+ createHashHistory,
79
80
  createHashRouter,
81
+ createMemoryHistory,
80
82
  createMemoryRouter,
81
83
  createPath,
82
84
  createRouter,
@@ -139,7 +141,7 @@ import {
139
141
  withComponentProps,
140
142
  withErrorBoundaryProps,
141
143
  withHydrateFallbackProps
142
- } from "./chunk-JMJ3UQ3L.mjs";
144
+ } from "./chunk-KYKH2NCS.mjs";
143
145
  export {
144
146
  Await,
145
147
  BrowserRouter,
@@ -187,6 +189,8 @@ export {
187
189
  createBrowserHistory as UNSAFE_createBrowserHistory,
188
190
  createClientRoutes as UNSAFE_createClientRoutes,
189
191
  createClientRoutesWithHMRRevalidationOptOut as UNSAFE_createClientRoutesWithHMRRevalidationOptOut,
192
+ createHashHistory as UNSAFE_createHashHistory,
193
+ createMemoryHistory as UNSAFE_createMemoryHistory,
190
194
  createRouter as UNSAFE_createRouter,
191
195
  decodeViaTurboStream as UNSAFE_decodeViaTurboStream,
192
196
  deserializeErrors as UNSAFE_deserializeErrors,
@@ -174,6 +174,27 @@ interface History {
174
174
  * entries to `createMemoryHistory` via its `initialEntries` option.
175
175
  */
176
176
  type InitialEntry = string | Partial<Location>;
177
+ type MemoryHistoryOptions = {
178
+ initialEntries?: InitialEntry[];
179
+ initialIndex?: number;
180
+ v5Compat?: boolean;
181
+ };
182
+ /**
183
+ * A memory history stores locations in memory. This is useful in stateful
184
+ * environments where there is no web browser, such as node tests or React
185
+ * Native.
186
+ */
187
+ interface MemoryHistory extends History {
188
+ /**
189
+ * The current index in the history stack.
190
+ */
191
+ readonly index: number;
192
+ }
193
+ /**
194
+ * Memory history stores the current location in memory. It is designed for use
195
+ * in stateful non-browser environments like tests and React Native.
196
+ */
197
+ declare function createMemoryHistory(options?: MemoryHistoryOptions): MemoryHistory;
177
198
  /**
178
199
  * A browser history stores the current location in regular URLs in a web
179
200
  * browser environment. This is the standard for most web apps and provides the
@@ -192,6 +213,29 @@ type BrowserHistoryOptions = UrlHistoryOptions;
192
213
  * @see https://github.com/remix-run/history/tree/main/docs/api-reference.md#createbrowserhistory
193
214
  */
194
215
  declare function createBrowserHistory(options?: BrowserHistoryOptions): BrowserHistory;
216
+ /**
217
+ * A hash history stores the current location in the fragment identifier portion
218
+ * of the URL in a web browser environment.
219
+ *
220
+ * This is ideal for apps that do not control the server for some reason
221
+ * (because the fragment identifier is never sent to the server), including some
222
+ * shared hosting environments that do not provide fine-grained controls over
223
+ * which pages are served at which URLs.
224
+ *
225
+ * @see https://github.com/remix-run/history/tree/main/docs/api-reference.md#hashhistory
226
+ */
227
+ interface HashHistory extends UrlHistory {
228
+ }
229
+ type HashHistoryOptions = UrlHistoryOptions;
230
+ /**
231
+ * Hash history stores the location in window.location.hash. This makes it ideal
232
+ * for situations where you don't want to send the location to the server for
233
+ * some reason, either because you do cannot configure it or the URL space is
234
+ * reserved for something else.
235
+ *
236
+ * @see https://github.com/remix-run/history/tree/main/docs/api-reference.md#createhashhistory
237
+ */
238
+ declare function createHashHistory(options?: HashHistoryOptions): HashHistory;
195
239
  /**
196
240
  * @private
197
241
  */
@@ -3285,4 +3329,4 @@ type RequestHandlerInstrumentationInfo = Readonly<{
3285
3329
  context: ReadonlyContext | undefined;
3286
3330
  }>;
3287
3331
 
3288
- export { type RouterState as $, type ActionFunction as A, type BlockerFunction as B, type ClientActionFunction as C, type DataStrategyResult as D, type PathMatch as E, type Func as F, type GetLoaderData as G, type HeadersFunction as H, type Navigation as I, Action as J, type RouteObject as K, type Location as L, type MetaFunction as M, type Normalize as N, type InitialEntry as O, type Params as P, type HydrationState as Q, type RouteModule$1 as R, type ShouldRevalidateFunction as S, type To as T, type UIMatch as U, type IndexRouteObject as V, type RouteComponentType as W, type HydrateFallbackType as X, type ErrorBoundaryType as Y, type NonIndexRouteObject as Z, type Equal as _, type ClientLoaderFunction as a, type RouterProviderProps as a$, type PatchRoutesOnNavigationFunction as a0, type DataRouteObject as a1, type StaticHandler as a2, type GetScrollPositionFunction as a3, type GetScrollRestorationKeyFunction as a4, type StaticHandlerContext as a5, type Fetcher as a6, type NavigationStates as a7, type RouterSubscriber as a8, type RouterNavigateOptions as a9, IDLE_FETCHER as aA, IDLE_BLOCKER as aB, data as aC, generatePath as aD, isRouteErrorResponse as aE, matchPath as aF, matchRoutes as aG, redirect as aH, redirectDocument as aI, replace as aJ, resolvePath as aK, type DataRouteMatch as aL, type Navigator as aM, type PatchRoutesOnNavigationFunctionArgs as aN, type RouteMatch as aO, AwaitContextProvider as aP, type AwaitProps as aQ, type IndexRouteProps as aR, type ClientOnErrorFunction as aS, type LayoutRouteProps as aT, type MemoryRouterOpts as aU, type MemoryRouterProps as aV, type NavigateProps as aW, type OutletProps as aX, type PathRouteProps as aY, type RouteProps as aZ, type RouterProps as a_, type RouterFetchOptions as aa, type RevalidationState as ab, type ActionFunctionArgs as ac, type DataStrategyFunctionArgs as ad, type DataStrategyMatch as ae, DataWithResponseInit as af, type ErrorResponse as ag, type FormEncType as ah, type FormMethod as ai, type HTMLFormMethod as aj, type LazyRouteFunction as ak, type LoaderFunctionArgs as al, type MiddlewareFunction as am, type PathParam as an, type RedirectFunction as ao, type RouterContext as ap, type ShouldRevalidateFunctionArgs as aq, createContext as ar, createPath as as, parsePath as at, type unstable_ServerInstrumentation as au, type unstable_InstrumentRequestHandlerFunction as av, type unstable_InstrumentRouterFunction as aw, type unstable_InstrumentRouteFunction as ax, type unstable_InstrumentationHandlerResult as ay, IDLE_NAVIGATION as az, type LinksFunction as b, type RoutesProps as b0, Await as b1, MemoryRouter as b2, Navigate as b3, Outlet as b4, Route as b5, Router as b6, RouterProvider as b7, Routes as b8, createMemoryRouter as b9, WithHydrateFallbackProps as bA, withHydrateFallbackProps as bB, WithErrorBoundaryProps as bC, withErrorBoundaryProps as bD, type RouteManifest as bE, type ServerRouteModule as bF, type History as bG, type FutureConfig as bH, type CreateStaticHandlerOptions as bI, createRoutesFromChildren as ba, createRoutesFromElements as bb, renderMatches as bc, type ClientActionFunctionArgs as bd, type ClientLoaderFunctionArgs as be, type HeadersArgs as bf, type MetaArgs as bg, type PageLinkDescriptor as bh, type HtmlLinkDescriptor as bi, type Future as bj, type unstable_SerializesTo as bk, createBrowserHistory as bl, invariant as bm, createRouter as bn, ErrorResponseImpl as bo, DataRouterContext as bp, DataRouterStateContext as bq, FetchersContext as br, LocationContext as bs, NavigationContext as bt, RouteContext as bu, ViewTransitionContext as bv, hydrationRouteProperties as bw, mapRouteProperties as bx, WithComponentProps as by, withComponentProps as bz, RouterContextProvider as c, type LoaderFunction as d, type RouterInit as e, type LinkDescriptor as f, type Pretty as g, type MetaDescriptor as h, type ServerDataFunctionArgs as i, type MiddlewareNextFunction as j, type ClientDataFunctionArgs as k, type ServerDataFrom as l, type GetActionData as m, type Router$1 as n, type RouteModules as o, type DataStrategyFunction as p, type MiddlewareEnabled as q, type AppLoadContext as r, type NavigateOptions as s, type Blocker as t, type unstable_ClientInstrumentation as u, type SerializeFrom as v, type RelativeRoutingType as w, type ParamParseKey as x, type Path as y, type PathPattern as z };
3332
+ export { type RouterState as $, type ActionFunction as A, type BlockerFunction as B, type ClientActionFunction as C, type DataStrategyResult as D, type PathMatch as E, type Func as F, type GetLoaderData as G, type HeadersFunction as H, type Navigation as I, Action as J, type RouteObject as K, type Location as L, type MetaFunction as M, type Normalize as N, type InitialEntry as O, type Params as P, type HydrationState as Q, type RouteModule$1 as R, type ShouldRevalidateFunction as S, type To as T, type UIMatch as U, type IndexRouteObject as V, type RouteComponentType as W, type HydrateFallbackType as X, type ErrorBoundaryType as Y, type NonIndexRouteObject as Z, type Equal as _, type ClientLoaderFunction as a, type RouterProviderProps as a$, type PatchRoutesOnNavigationFunction as a0, type DataRouteObject as a1, type StaticHandler as a2, type GetScrollPositionFunction as a3, type GetScrollRestorationKeyFunction as a4, type StaticHandlerContext as a5, type Fetcher as a6, type NavigationStates as a7, type RouterSubscriber as a8, type RouterNavigateOptions as a9, IDLE_FETCHER as aA, IDLE_BLOCKER as aB, data as aC, generatePath as aD, isRouteErrorResponse as aE, matchPath as aF, matchRoutes as aG, redirect as aH, redirectDocument as aI, replace as aJ, resolvePath as aK, type DataRouteMatch as aL, type Navigator as aM, type PatchRoutesOnNavigationFunctionArgs as aN, type RouteMatch as aO, AwaitContextProvider as aP, type AwaitProps as aQ, type IndexRouteProps as aR, type ClientOnErrorFunction as aS, type LayoutRouteProps as aT, type MemoryRouterOpts as aU, type MemoryRouterProps as aV, type NavigateProps as aW, type OutletProps as aX, type PathRouteProps as aY, type RouteProps as aZ, type RouterProps as a_, type RouterFetchOptions as aa, type RevalidationState as ab, type ActionFunctionArgs as ac, type DataStrategyFunctionArgs as ad, type DataStrategyMatch as ae, DataWithResponseInit as af, type ErrorResponse as ag, type FormEncType as ah, type FormMethod as ai, type HTMLFormMethod as aj, type LazyRouteFunction as ak, type LoaderFunctionArgs as al, type MiddlewareFunction as am, type PathParam as an, type RedirectFunction as ao, type RouterContext as ap, type ShouldRevalidateFunctionArgs as aq, createContext as ar, createPath as as, parsePath as at, type unstable_ServerInstrumentation as au, type unstable_InstrumentRequestHandlerFunction as av, type unstable_InstrumentRouterFunction as aw, type unstable_InstrumentRouteFunction as ax, type unstable_InstrumentationHandlerResult as ay, IDLE_NAVIGATION as az, type LinksFunction as b, type RoutesProps as b0, Await as b1, MemoryRouter as b2, Navigate as b3, Outlet as b4, Route as b5, Router as b6, RouterProvider as b7, Routes as b8, createMemoryRouter as b9, WithComponentProps as bA, withComponentProps as bB, WithHydrateFallbackProps as bC, withHydrateFallbackProps as bD, WithErrorBoundaryProps as bE, withErrorBoundaryProps as bF, type RouteManifest as bG, type ServerRouteModule as bH, type History as bI, type FutureConfig as bJ, type CreateStaticHandlerOptions as bK, createRoutesFromChildren as ba, createRoutesFromElements as bb, renderMatches as bc, type ClientActionFunctionArgs as bd, type ClientLoaderFunctionArgs as be, type HeadersArgs as bf, type MetaArgs as bg, type PageLinkDescriptor as bh, type HtmlLinkDescriptor as bi, type Future as bj, type unstable_SerializesTo as bk, createMemoryHistory as bl, createBrowserHistory as bm, createHashHistory as bn, invariant as bo, createRouter as bp, ErrorResponseImpl as bq, DataRouterContext as br, DataRouterStateContext as bs, FetchersContext as bt, LocationContext as bu, NavigationContext as bv, RouteContext as bw, ViewTransitionContext as bx, hydrationRouteProperties as by, mapRouteProperties as bz, RouterContextProvider as c, type LoaderFunction as d, type RouterInit as e, type LinkDescriptor as f, type Pretty as g, type MetaDescriptor as h, type ServerDataFunctionArgs as i, type MiddlewareNextFunction as j, type ClientDataFunctionArgs as k, type ServerDataFrom as l, type GetActionData as m, type Router$1 as n, type RouteModules as o, type DataStrategyFunction as p, type MiddlewareEnabled as q, type AppLoadContext as r, type NavigateOptions as s, type Blocker as t, type unstable_ClientInstrumentation as u, type SerializeFrom as v, type RelativeRoutingType as w, type ParamParseKey as x, type Path as y, type PathPattern as z };
@@ -1,5 +1,5 @@
1
- import { R as RouteModule, h as LinkDescriptor, L as Location, F as Func, i as Pretty, j as MetaDescriptor, G as GetLoaderData, k as ServerDataFunctionArgs, l as MiddlewareNextFunction, m as ClientDataFunctionArgs, D as DataStrategyResult, n as ServerDataFrom, N as Normalize, o as GetActionData } from '../../router-5fbeEIMQ.mjs';
2
- import { R as RouteFiles, P as Pages } from '../../register-DTJJbt1o.mjs';
1
+ import { R as RouteModule, h as LinkDescriptor, L as Location, F as Func, i as Pretty, j as MetaDescriptor, G as GetLoaderData, k as ServerDataFunctionArgs, l as MiddlewareNextFunction, m as ClientDataFunctionArgs, D as DataStrategyResult, n as ServerDataFrom, N as Normalize, o as GetActionData } from '../../router-5iOvts3c.mjs';
2
+ import { R as RouteFiles, P as Pages } from '../../register-CS_tiXsm.mjs';
3
3
  import 'react';
4
4
 
5
5
  type MaybePromise<T> = T | Promise<T>;
@@ -1,5 +1,5 @@
1
- import { R as RouteModule, f as LinkDescriptor, L as Location, F as Func, g as Pretty, h as MetaDescriptor, G as GetLoaderData, i as ServerDataFunctionArgs, j as MiddlewareNextFunction, k as ClientDataFunctionArgs, D as DataStrategyResult, l as ServerDataFrom, N as Normalize, m as GetActionData } from '../../instrumentation-BlrVzjbg.js';
2
- import { R as RouteFiles, P as Pages } from '../../register-BGQUMCK4.js';
1
+ import { R as RouteModule, f as LinkDescriptor, L as Location, F as Func, g as Pretty, h as MetaDescriptor, G as GetLoaderData, i as ServerDataFunctionArgs, j as MiddlewareNextFunction, k as ClientDataFunctionArgs, D as DataStrategyResult, l as ServerDataFrom, N as Normalize, m as GetActionData } from '../../instrumentation-DvHY1sgY.js';
2
+ import { R as RouteFiles, P as Pages } from '../../register-Bm80E9qL.js';
3
3
  import 'react';
4
4
 
5
5
  type MaybePromise<T> = T | Promise<T>;
@@ -1,5 +1,5 @@
1
1
  "use strict";/**
2
- * react-router v7.11.0
2
+ * react-router v7.12.0-pre.0
3
3
  *
4
4
  * Copyright (c) Remix Software Inc.
5
5
  *
@@ -1,5 +1,5 @@
1
1
  /**
2
- * react-router v7.11.0
2
+ * react-router v7.12.0-pre.0
3
3
  *
4
4
  * Copyright (c) Remix Software Inc.
5
5
  *
@@ -1,4 +1,4 @@
1
- import { R as RouteModule } from './instrumentation-BlrVzjbg.js';
1
+ import { R as RouteModule } from './instrumentation-DvHY1sgY.js';
2
2
 
3
3
  /**
4
4
  * Apps can use this interface to "register" app-wide types for React Router via interface declaration merging and module augmentation.
@@ -1,4 +1,4 @@
1
- import { R as RouteModule } from './router-5fbeEIMQ.mjs';
1
+ import { R as RouteModule } from './router-5iOvts3c.mjs';
2
2
 
3
3
  /**
4
4
  * Apps can use this interface to "register" app-wide types for React Router via interface declaration merging and module augmentation.
@@ -164,6 +164,27 @@ interface History {
164
164
  * entries to `createMemoryHistory` via its `initialEntries` option.
165
165
  */
166
166
  type InitialEntry = string | Partial<Location>;
167
+ type MemoryHistoryOptions = {
168
+ initialEntries?: InitialEntry[];
169
+ initialIndex?: number;
170
+ v5Compat?: boolean;
171
+ };
172
+ /**
173
+ * A memory history stores locations in memory. This is useful in stateful
174
+ * environments where there is no web browser, such as node tests or React
175
+ * Native.
176
+ */
177
+ interface MemoryHistory extends History {
178
+ /**
179
+ * The current index in the history stack.
180
+ */
181
+ readonly index: number;
182
+ }
183
+ /**
184
+ * Memory history stores the current location in memory. It is designed for use
185
+ * in stateful non-browser environments like tests and React Native.
186
+ */
187
+ declare function createMemoryHistory(options?: MemoryHistoryOptions): MemoryHistory;
167
188
  /**
168
189
  * A browser history stores the current location in regular URLs in a web
169
190
  * browser environment. This is the standard for most web apps and provides the
@@ -182,6 +203,29 @@ type BrowserHistoryOptions = UrlHistoryOptions;
182
203
  * @see https://github.com/remix-run/history/tree/main/docs/api-reference.md#createbrowserhistory
183
204
  */
184
205
  declare function createBrowserHistory(options?: BrowserHistoryOptions): BrowserHistory;
206
+ /**
207
+ * A hash history stores the current location in the fragment identifier portion
208
+ * of the URL in a web browser environment.
209
+ *
210
+ * This is ideal for apps that do not control the server for some reason
211
+ * (because the fragment identifier is never sent to the server), including some
212
+ * shared hosting environments that do not provide fine-grained controls over
213
+ * which pages are served at which URLs.
214
+ *
215
+ * @see https://github.com/remix-run/history/tree/main/docs/api-reference.md#hashhistory
216
+ */
217
+ interface HashHistory extends UrlHistory {
218
+ }
219
+ type HashHistoryOptions = UrlHistoryOptions;
220
+ /**
221
+ * Hash history stores the location in window.location.hash. This makes it ideal
222
+ * for situations where you don't want to send the location to the server for
223
+ * some reason, either because you do cannot configure it or the URL space is
224
+ * reserved for something else.
225
+ *
226
+ * @see https://github.com/remix-run/history/tree/main/docs/api-reference.md#createhashhistory
227
+ */
228
+ declare function createHashHistory(options?: HashHistoryOptions): HashHistory;
185
229
  /**
186
230
  * @private
187
231
  */
@@ -3285,4 +3329,4 @@ interface CreateStaticHandlerOptions {
3285
3329
  future?: {};
3286
3330
  }
3287
3331
 
3288
- export { type NonIndexRouteObject as $, type ActionFunction as A, type BlockerFunction as B, type ClientActionFunction as C, type DataStrategyResult as D, type Path as E, type Func as F, type GetLoaderData as G, type HeadersFunction as H, type PathPattern as I, type PathMatch as J, type Navigation as K, type Location as L, type MetaFunction as M, type Normalize as N, Action as O, type Params as P, type RouteObject as Q, type RouteModule$1 as R, type ShouldRevalidateFunction as S, type To as T, type UIMatch as U, type InitialEntry as V, type HydrationState as W, type IndexRouteObject as X, type RouteComponentType as Y, type HydrateFallbackType as Z, type ErrorBoundaryType as _, type ClientLoaderFunction as a, type RouterProps as a$, type Equal as a0, type RouterState as a1, type PatchRoutesOnNavigationFunction as a2, type DataRouteObject as a3, type StaticHandler as a4, type GetScrollPositionFunction as a5, type GetScrollRestorationKeyFunction as a6, type StaticHandlerContext as a7, type Fetcher as a8, type NavigationStates as a9, type unstable_InstrumentationHandlerResult as aA, IDLE_NAVIGATION as aB, IDLE_FETCHER as aC, IDLE_BLOCKER as aD, data as aE, generatePath as aF, isRouteErrorResponse as aG, matchPath as aH, matchRoutes as aI, redirect as aJ, redirectDocument as aK, replace as aL, resolvePath as aM, type DataRouteMatch as aN, type Navigator as aO, type PatchRoutesOnNavigationFunctionArgs as aP, type RouteMatch as aQ, AwaitContextProvider as aR, type AwaitProps as aS, type IndexRouteProps as aT, type LayoutRouteProps as aU, type MemoryRouterOpts as aV, type MemoryRouterProps as aW, type NavigateProps as aX, type OutletProps as aY, type PathRouteProps as aZ, type RouteProps as a_, type RouterSubscriber as aa, type RouterNavigateOptions as ab, type RouterFetchOptions as ac, type RevalidationState as ad, type ActionFunctionArgs as ae, type DataStrategyFunctionArgs as af, type DataStrategyMatch as ag, DataWithResponseInit as ah, type ErrorResponse as ai, type FormEncType as aj, type FormMethod as ak, type HTMLFormMethod as al, type LazyRouteFunction as am, type LoaderFunctionArgs as an, type MiddlewareFunction as ao, type PathParam as ap, type RedirectFunction as aq, type RouterContext as ar, type ShouldRevalidateFunctionArgs as as, createContext as at, createPath as au, parsePath as av, type unstable_ServerInstrumentation as aw, type unstable_InstrumentRequestHandlerFunction as ax, type unstable_InstrumentRouterFunction as ay, type unstable_InstrumentRouteFunction as az, type LinksFunction as b, type RoutesProps as b0, Await as b1, MemoryRouter as b2, Navigate as b3, Outlet as b4, Route as b5, Router$1 as b6, RouterProvider as b7, Routes as b8, createMemoryRouter as b9, WithHydrateFallbackProps as bA, withHydrateFallbackProps as bB, WithErrorBoundaryProps as bC, withErrorBoundaryProps as bD, type RouteManifest as bE, type ServerRouteModule as bF, type History as bG, type FutureConfig as bH, type CreateStaticHandlerOptions as bI, createRoutesFromChildren as ba, createRoutesFromElements as bb, renderMatches as bc, type ClientActionFunctionArgs as bd, type ClientLoaderFunctionArgs as be, type HeadersArgs as bf, type MetaArgs as bg, type PageLinkDescriptor as bh, type HtmlLinkDescriptor as bi, type Future as bj, type unstable_SerializesTo as bk, createBrowserHistory as bl, invariant as bm, createRouter as bn, ErrorResponseImpl as bo, DataRouterContext as bp, DataRouterStateContext as bq, FetchersContext as br, LocationContext as bs, NavigationContext as bt, RouteContext as bu, ViewTransitionContext as bv, hydrationRouteProperties as bw, mapRouteProperties as bx, WithComponentProps as by, withComponentProps as bz, RouterContextProvider as c, type LoaderFunction as d, type RouterInit as e, type RouterProviderProps as f, type ClientOnErrorFunction as g, type LinkDescriptor as h, type Pretty as i, type MetaDescriptor as j, type ServerDataFunctionArgs as k, type MiddlewareNextFunction as l, type ClientDataFunctionArgs as m, type ServerDataFrom as n, type GetActionData as o, type Router as p, type RouteModules as q, type DataStrategyFunction as r, type MiddlewareEnabled as s, type AppLoadContext as t, type unstable_ClientInstrumentation as u, type NavigateOptions as v, type Blocker as w, type SerializeFrom as x, type RelativeRoutingType as y, type ParamParseKey as z };
3332
+ export { type NonIndexRouteObject as $, type ActionFunction as A, type BlockerFunction as B, type ClientActionFunction as C, type DataStrategyResult as D, type Path as E, type Func as F, type GetLoaderData as G, type HeadersFunction as H, type PathPattern as I, type PathMatch as J, type Navigation as K, type Location as L, type MetaFunction as M, type Normalize as N, Action as O, type Params as P, type RouteObject as Q, type RouteModule$1 as R, type ShouldRevalidateFunction as S, type To as T, type UIMatch as U, type InitialEntry as V, type HydrationState as W, type IndexRouteObject as X, type RouteComponentType as Y, type HydrateFallbackType as Z, type ErrorBoundaryType as _, type ClientLoaderFunction as a, type RouterProps as a$, type Equal as a0, type RouterState as a1, type PatchRoutesOnNavigationFunction as a2, type DataRouteObject as a3, type StaticHandler as a4, type GetScrollPositionFunction as a5, type GetScrollRestorationKeyFunction as a6, type StaticHandlerContext as a7, type Fetcher as a8, type NavigationStates as a9, type unstable_InstrumentationHandlerResult as aA, IDLE_NAVIGATION as aB, IDLE_FETCHER as aC, IDLE_BLOCKER as aD, data as aE, generatePath as aF, isRouteErrorResponse as aG, matchPath as aH, matchRoutes as aI, redirect as aJ, redirectDocument as aK, replace as aL, resolvePath as aM, type DataRouteMatch as aN, type Navigator as aO, type PatchRoutesOnNavigationFunctionArgs as aP, type RouteMatch as aQ, AwaitContextProvider as aR, type AwaitProps as aS, type IndexRouteProps as aT, type LayoutRouteProps as aU, type MemoryRouterOpts as aV, type MemoryRouterProps as aW, type NavigateProps as aX, type OutletProps as aY, type PathRouteProps as aZ, type RouteProps as a_, type RouterSubscriber as aa, type RouterNavigateOptions as ab, type RouterFetchOptions as ac, type RevalidationState as ad, type ActionFunctionArgs as ae, type DataStrategyFunctionArgs as af, type DataStrategyMatch as ag, DataWithResponseInit as ah, type ErrorResponse as ai, type FormEncType as aj, type FormMethod as ak, type HTMLFormMethod as al, type LazyRouteFunction as am, type LoaderFunctionArgs as an, type MiddlewareFunction as ao, type PathParam as ap, type RedirectFunction as aq, type RouterContext as ar, type ShouldRevalidateFunctionArgs as as, createContext as at, createPath as au, parsePath as av, type unstable_ServerInstrumentation as aw, type unstable_InstrumentRequestHandlerFunction as ax, type unstable_InstrumentRouterFunction as ay, type unstable_InstrumentRouteFunction as az, type LinksFunction as b, type RoutesProps as b0, Await as b1, MemoryRouter as b2, Navigate as b3, Outlet as b4, Route as b5, Router$1 as b6, RouterProvider as b7, Routes as b8, createMemoryRouter as b9, WithComponentProps as bA, withComponentProps as bB, WithHydrateFallbackProps as bC, withHydrateFallbackProps as bD, WithErrorBoundaryProps as bE, withErrorBoundaryProps as bF, type RouteManifest as bG, type ServerRouteModule as bH, type History as bI, type FutureConfig as bJ, type CreateStaticHandlerOptions as bK, createRoutesFromChildren as ba, createRoutesFromElements as bb, renderMatches as bc, type ClientActionFunctionArgs as bd, type ClientLoaderFunctionArgs as be, type HeadersArgs as bf, type MetaArgs as bg, type PageLinkDescriptor as bh, type HtmlLinkDescriptor as bi, type Future as bj, type unstable_SerializesTo as bk, createMemoryHistory as bl, createBrowserHistory as bm, createHashHistory as bn, invariant as bo, createRouter as bp, ErrorResponseImpl as bq, DataRouterContext as br, DataRouterStateContext as bs, FetchersContext as bt, LocationContext as bu, NavigationContext as bv, RouteContext as bw, ViewTransitionContext as bx, hydrationRouteProperties as by, mapRouteProperties as bz, RouterContextProvider as c, type LoaderFunction as d, type RouterInit as e, type RouterProviderProps as f, type ClientOnErrorFunction as g, type LinkDescriptor as h, type Pretty as i, type MetaDescriptor as j, type ServerDataFunctionArgs as k, type MiddlewareNextFunction as l, type ClientDataFunctionArgs as m, type ServerDataFrom as n, type GetActionData as o, type Router as p, type RouteModules as q, type DataStrategyFunction as r, type MiddlewareEnabled as s, type AppLoadContext as t, type unstable_ClientInstrumentation as u, type NavigateOptions as v, type Blocker as w, type SerializeFrom as x, type RelativeRoutingType as y, type ParamParseKey as z };
@@ -1,5 +1,5 @@
1
1
  import * as React from 'react';
2
- import { L as Location, C as ClientActionFunction, a as ClientLoaderFunction, b as LinksFunction, M as MetaFunction, S as ShouldRevalidateFunction, P as Params, c as RouterContextProvider, A as ActionFunction, H as HeadersFunction, d as LoaderFunction, e as RouterInit } from './instrumentation-BlrVzjbg.js';
2
+ import { L as Location, C as ClientActionFunction, a as ClientLoaderFunction, b as LinksFunction, M as MetaFunction, S as ShouldRevalidateFunction, P as Params, c as RouterContextProvider, A as ActionFunction, H as HeadersFunction, d as LoaderFunction, e as RouterInit } from './router-5iOvts3c.mjs';
3
3
 
4
4
  type RSCRouteConfigEntryBase = {
5
5
  action?: ActionFunction;
@@ -138,6 +138,7 @@ type LoadServerActionFunction = (id: string) => Promise<Function>;
138
138
  * @category RSC
139
139
  * @mode data
140
140
  * @param opts Options
141
+ * @param opts.allowedActionOrigins Origin patterns that are allowed to execute actions.
141
142
  * @param opts.basename The basename to use when matching the request.
142
143
  * @param opts.createTemporaryReferenceSet A function that returns a temporary
143
144
  * reference set for the request, used to track temporary references in the [RSC](https://react.dev/reference/rsc/server-components)
@@ -167,7 +168,8 @@ type LoadServerActionFunction = (id: string) => Promise<Function>;
167
168
  * that contains the [RSC](https://react.dev/reference/rsc/server-components)
168
169
  * data for hydration.
169
170
  */
170
- declare function matchRSCServerRequest({ createTemporaryReferenceSet, basename, decodeReply, requestContext, loadServerAction, decodeAction, decodeFormState, onError, request, routes, generateResponse, }: {
171
+ declare function matchRSCServerRequest({ allowedActionOrigins, createTemporaryReferenceSet, basename, decodeReply, requestContext, loadServerAction, decodeAction, decodeFormState, onError, request, routes, generateResponse, }: {
172
+ allowedActionOrigins?: string[];
171
173
  createTemporaryReferenceSet: () => unknown;
172
174
  basename?: string;
173
175
  decodeReply?: DecodeReplyFunction;
@@ -1,5 +1,5 @@
1
1
  import * as React from 'react';
2
- import { L as Location, C as ClientActionFunction, a as ClientLoaderFunction, b as LinksFunction, M as MetaFunction, S as ShouldRevalidateFunction, P as Params, c as RouterContextProvider, A as ActionFunction, H as HeadersFunction, d as LoaderFunction, e as RouterInit } from './instrumentation-BlrVzjbg.js';
2
+ import { L as Location, C as ClientActionFunction, a as ClientLoaderFunction, b as LinksFunction, M as MetaFunction, S as ShouldRevalidateFunction, P as Params, c as RouterContextProvider, A as ActionFunction, H as HeadersFunction, d as LoaderFunction, e as RouterInit } from './instrumentation-DvHY1sgY.js';
3
3
 
4
4
  type RSCRouteConfigEntryBase = {
5
5
  action?: ActionFunction;
@@ -138,6 +138,7 @@ type LoadServerActionFunction = (id: string) => Promise<Function>;
138
138
  * @category RSC
139
139
  * @mode data
140
140
  * @param opts Options
141
+ * @param opts.allowedActionOrigins Origin patterns that are allowed to execute actions.
141
142
  * @param opts.basename The basename to use when matching the request.
142
143
  * @param opts.createTemporaryReferenceSet A function that returns a temporary
143
144
  * reference set for the request, used to track temporary references in the [RSC](https://react.dev/reference/rsc/server-components)
@@ -167,7 +168,8 @@ type LoadServerActionFunction = (id: string) => Promise<Function>;
167
168
  * that contains the [RSC](https://react.dev/reference/rsc/server-components)
168
169
  * data for hydration.
169
170
  */
170
- declare function matchRSCServerRequest({ createTemporaryReferenceSet, basename, decodeReply, requestContext, loadServerAction, decodeAction, decodeFormState, onError, request, routes, generateResponse, }: {
171
+ declare function matchRSCServerRequest({ allowedActionOrigins, createTemporaryReferenceSet, basename, decodeReply, requestContext, loadServerAction, decodeAction, decodeFormState, onError, request, routes, generateResponse, }: {
172
+ allowedActionOrigins?: string[];
171
173
  createTemporaryReferenceSet: () => unknown;
172
174
  basename?: string;
173
175
  decodeReply?: DecodeReplyFunction;