fix(deps): update react-router monorepo to ^7.6.2 #11692
+13
−29
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This PR contains the following updates:
^7.3.0
->^7.6.2
^7.3.0
->^7.6.2
Release Notes
remix-run/react-router (react-router)
v7.6.2
Compare Source
Patch Changes
with-props
chunk in Framework Mode by moving route module component prop logic from the Vite plugin toreact-router
(#13650)headers()
function processing for use with RSC (#13639)v7.6.1
Compare Source
Patch Changes
Update
Route.MetaArgs
to reflect thatdata
can be potentiallyundefined
(#13563)This is primarily for cases where a route
loader
threw an error to it's ownErrorBoundary
. but it also arises in the case of a 404 which renders the rootErrorBoundary
/meta
but the root loader did not run because not routes matched.Partially revert optimization added in
7.1.4
to reduce calls tomatchRoutes
because it surfaced other issues (#13562)Fix typegen when same route is used at multiple paths (#13574)
For example,
routes/route.tsx
is used at 4 different paths here:Previously, typegen would arbitrarily pick one of these paths to be the "winner" and generate types for the route module based on that path.
Now, typegen creates unions as necessary for alternate paths for the same route file.
Better types for
params
(#13543)For example:
Previously,
params
for theroutes/layout.tsx
route were calculated as{ p: string, l: string }
.This incorrectly ignores params that could come from child routes.
If visiting
/parent/1/layout/2/child1/3/4
, the actual params passed toroutes/layout.tsx
will have a type of{ p: string, l: string, c1a: string, c1b: string }
.Now,
params
are aware of child routes and autocompletion will include child params as optionals:You can also narrow the types for
params
as it is implemented as a normalized union of params for each page that includesroutes/layout.tsx
:UNSTABLE: renamed internal
react-router/route-module
export toreact-router/internal
UNSTABLE: removed
Info
export from generated+types/*
filesAvoid initial fetcher execution 404 error when Lazy Route Discovery is interrupted by a navigation (#13564)
href replaces splats
*
(#13593)v7.6.0
Compare Source
Minor Changes
Added a new
react-router.config.ts
routeDiscovery
option to configure Lazy Route Discovery behavior. (#13451)/__manifest
path:routeDiscovery: { mode: "lazy", manifestPath: "/__manifest" }
routeDiscovery: { mode: "lazy", manifestPath: "/custom-manifest" }
routeDiscovery: { mode: "initial" }
Add support for route component props in
createRoutesStub
. This allows you to unit test your route components using the props instead of the hooks: (#13528)Patch Changes
Fix
react-router
module augmentation forNodeNext
(#13498)Don't bundle
react-router
inreact-router/dom
CJS export (#13497)Fix bug where a submitting
fetcher
would get stuck in aloading
state if a revalidatingloader
redirected (#12873)Fix hydration error if a server
loader
returnedundefined
(#13496)Fix initial load 404 scenarios in data mode (#13500)
Stabilize
useRevalidator
'srevalidate
function (#13542)Preserve status code if a
clientAction
throws adata()
result in framework mode (#13522)Be defensive against leading double slashes in paths to avoid
Invalid URL
errors from the URL constructor (#13510)new URL("//", window.location.origin)
Remove
Navigator
declaration fornavigator.connection.saveData
to avoid messing with any other types beyondsaveData
in userland (#13512)Fix
handleError
params
values on.data
requests for routes with a dynamic param as the last URL segment (#13481)Don't trigger an
ErrorBoundary
UI before the reload when we detect a manifest verison mismatch in Lazy Route Discovery (#13480)Inline
[email protected]
dependency and fix decoding ordering of Map/Set instances (#13518)Only render dev warnings in DEV mode (#13461)
UNSTABLE: Fix a few bugs with error bubbling in middleware use-cases (#13538)
Short circuit post-processing on aborted
dataStrategy
requests (#13521)Cannot read properties of undefined (reading 'result')
v7.5.3
Compare Source
Patch Changes
loaderData
being cleared at the handlingErrorBoundary
route (#13476)clientLoader.hydrate
initial load executions (#13477)v7.5.2
Compare Source
Patch Changes
Update Single Fetch to also handle the 204 redirects used in
?_data
requests in Remix v2 (#13364).data
requests from outside the scope of React Router (i.e., anexpress
/hono
middleware)Adjust approach for Prerendering/SPA Mode via headers (#13453)
v7.5.1
Compare Source
Patch Changes
Fix single fetch bug where no revalidation request would be made when navigating upwards to a reused parent route (#13253)
When using the object-based
route.lazy
API, theHydrateFallback
andhydrateFallbackElement
properties are now skipped when lazy loading routes after hydration. (#13376)If you move the code for these properties into a separate file, you can use this optimization to avoid downloading unused hydration code. For example:
Properly revalidate prerendered paths when param values change (#13380)
UNSTABLE: Add a new
unstable_runClientMiddleware
argument todataStrategy
to enable middleware execution in customdataStrategy
implementations (#13395)UNSTABLE: Add better error messaging when
getLoadContext
is not updated to return aMap
" (#13242)Do not automatically add
null
tostaticHandler.query()
context.loaderData
if routes do not have loaders (#13223)undefined
from loaders, our prior check ofloaderData[routeId] !== undefined
was no longer sufficient and was changed to arouteId in loaderData
check - thesenull
values can cause issues for this new checkcreateStaticHandler()
/<StaticRouterProvider>
, and usingcontext.loaderData
to control<RouterProvider>
hydration behavior on the clientFix prerendering when a loader returns a redirect (#13365)
UNSTABLE: Update context type for
LoaderFunctionArgs
/ActionFunctionArgs
when middleware is enabled (#13381)Add support for the new
unstable_shouldCallHandler
/unstable_shouldRevalidateArgs
APIs indataStrategy
(#13253)v7.5.0
Compare Source
Minor Changes
Add granular object-based API for
route.lazy
to support lazy loading of individual route properties, for example: (#13294)Breaking change for
route.unstable_lazyMiddleware
consumersThe
route.unstable_lazyMiddleware
property is no longer supported. If you want to lazily load middleware, you must use the new object-basedroute.lazy
API withroute.lazy.unstable_middleware
, for example:Patch Changes
unstable_subResourceIntegrity
future flag that enables generation of an importmap with integrity for the scripts that will be loaded by the browser. (#13163)v7.4.1
Compare Source
Patch Changes
Fix types on
unstable_MiddlewareFunction
to avoid type errors when a middleware doesn't return a value (#13311)Dedupe calls to
route.lazy
functions (#13260)Add support for
route.unstable_lazyMiddleware
function to allow lazy loading of middleware logic. (#13210)Breaking change for
unstable_middleware
consumersThe
route.unstable_middleware
property is no longer supported in the return value fromroute.lazy
. If you want to lazily load middleware, you must useroute.unstable_lazyMiddleware
.v7.4.0
Compare Source
Patch Changes
shouldRevalidate
behavior forclientLoader
-only routes inssr:true
apps (#13221)RequestHandler
loadContext
parameter type when middleware is enabled (#13204)Route.unstable_MiddlewareFunction
to have a return value ofResponse | undefined
instead ofResponse | void
becaue you should not return anything if you aren't returning theResponse
(#13199)next()
and are no longer leaking theMiddlewareError
implementation detail (#13180)remix-run/react-router (react-router-dom)
v7.6.2
Compare Source
Patch Changes
[email protected]
v7.6.1
Compare Source
Patch Changes
[email protected]
v7.6.0
Compare Source
Patch Changes
[email protected]
v7.5.3
Compare Source
Patch Changes
[email protected]
v7.5.2
Compare Source
Patch Changes
[email protected]
v7.5.1
Compare Source
Patch Changes
[email protected]
v7.5.0
Compare Source
Patch Changes
[email protected]
v7.4.1
Compare Source
Patch Changes
[email protected]
v7.4.0
Compare Source
Patch Changes
[email protected]
Configuration
📅 Schedule: Branch creation - At any time (no schedule defined), Automerge - At any time (no schedule defined).
🚦 Automerge: Disabled by config. Please merge this manually once you are satisfied.
♻ Rebasing: Whenever PR becomes conflicted, or you tick the rebase/retry checkbox.
🔕 Ignore: Close this PR and you won't be reminded about these updates again.
This PR was generated by Mend Renovate. View the repository job log.