diff --git a/.changeset/pre.json b/.changeset/pre.json
index 530126ccbe..a7eeca5d13 100644
--- a/.changeset/pre.json
+++ b/.changeset/pre.json
@@ -8,5 +8,20 @@
"react-router-native": "6.10.0",
"@remix-run/router": "1.5.0"
},
- "changesets": []
+ "changesets": [
+ "console-log-loader-error",
+ "descendant-routes-data-errors",
+ "disallow-return-undefined-type",
+ "fetcher-404",
+ "fetcher-basename",
+ "fix-component-rerenders-router",
+ "fix-component-rerenders",
+ "fix-fetcher-revalidation",
+ "invalid-link-to",
+ "navigate-in-effect",
+ "remove-use-sync-external-store",
+ "revalidate-error-boundary",
+ "revalidating-fetcher-controller",
+ "stable-navigate-submit"
+ ]
}
diff --git a/packages/react-router-dom-v5-compat/CHANGELOG.md b/packages/react-router-dom-v5-compat/CHANGELOG.md
index 59b46b0d40..de089f6b6c 100644
--- a/packages/react-router-dom-v5-compat/CHANGELOG.md
+++ b/packages/react-router-dom-v5-compat/CHANGELOG.md
@@ -1,5 +1,13 @@
# `react-router-dom-v5-compat`
+## 6.11.0-pre.0
+
+### Patch Changes
+
+- Updated dependencies:
+ - `react-router@6.11.0-pre.0`
+ - `react-router-dom@6.11.0-pre.0`
+
## 6.10.0
### Patch Changes
diff --git a/packages/react-router-dom-v5-compat/package.json b/packages/react-router-dom-v5-compat/package.json
index 7ac73db568..d87300e524 100644
--- a/packages/react-router-dom-v5-compat/package.json
+++ b/packages/react-router-dom-v5-compat/package.json
@@ -1,6 +1,6 @@
{
"name": "react-router-dom-v5-compat",
- "version": "6.10.0",
+ "version": "6.11.0-pre.0",
"description": "Migration path to React Router v6 from v4/5",
"keywords": [
"react",
@@ -24,7 +24,7 @@
"types": "./dist/index.d.ts",
"dependencies": {
"history": "^5.3.0",
- "react-router": "6.10.0"
+ "react-router": "6.11.0-pre.0"
},
"peerDependencies": {
"react": ">=16.8",
diff --git a/packages/react-router-dom/CHANGELOG.md b/packages/react-router-dom/CHANGELOG.md
index d745023467..3751a11500 100644
--- a/packages/react-router-dom/CHANGELOG.md
+++ b/packages/react-router-dom/CHANGELOG.md
@@ -1,5 +1,28 @@
# `react-router-dom`
+## 6.11.0-pre.0
+
+### Minor Changes
+
+- - Enable relative routing in the `@remix-run/router` when providing a source route ID from which the path is relative to: ([#10336](https://github.com/remix-run/react-router/pull/10336))
+
+ - Example: `router.navigate("../path", { fromRouteId: "some-route" })`.
+ - This also applies to `router.fetch` which already receives a source route ID
+
+ - Introduce a new `@remix-run/router` `future.v7_prependBasename` flag to enable `basename` prefixing to all paths coming into `router.navigate` and `router.fetch`.
+ - Previously the `basename` was prepended in the React Router layer, but now that relative routing is being handled by the router we need prepend the `basename` _after_ resolving any relative paths
+ - This also enables `basename` support in `useFetcher` as well
+
+### Patch Changes
+
+- Fix inadvertent re-renders when using `Component` instead of `element` on a route definition ([#10287](https://github.com/remix-run/react-router/pull/10287))
+- Fail gracefully on `` and other invalid URL values ([#10367](https://github.com/remix-run/react-router/pull/10367))
+- Switched from `useSyncExternalStore` to `useState` for internal `@remix-run/router` router state syncing in ``. We found some [subtle bugs](https://codesandbox.io/s/use-sync-external-store-loop-9g7b81) where router state updates got propagated _before_ other normal `useState` updates, which could lead to footguns in `useEffect` calls. ([#10377](https://github.com/remix-run/react-router/pull/10377))
+- When using a `RouterProvider`, `useNavigate`/`useSubmit`/`fetcher.submit` are now stable across location changes, since we can handle relative routing via the `@remix-run/router` instance and get rid of our dependence on `useLocation()`. When using `BrowserRouter`, these hooks remain unstable across location changes because they still rely on `useLocation()`. ([#10336](https://github.com/remix-run/react-router/pull/10336))
+- Updated dependencies:
+ - `react-router@6.11.0-pre.0`
+ - `@remix-run/router@1.6.0-pre.0`
+
## 6.10.0
### Minor Changes
diff --git a/packages/react-router-dom/package.json b/packages/react-router-dom/package.json
index 910d1a3789..da6cc16ce3 100644
--- a/packages/react-router-dom/package.json
+++ b/packages/react-router-dom/package.json
@@ -1,6 +1,6 @@
{
"name": "react-router-dom",
- "version": "6.10.0",
+ "version": "6.11.0-pre.0",
"description": "Declarative routing for React web applications",
"keywords": [
"react",
@@ -23,8 +23,8 @@
"module": "./dist/index.js",
"types": "./dist/index.d.ts",
"dependencies": {
- "@remix-run/router": "1.5.0",
- "react-router": "6.10.0"
+ "@remix-run/router": "1.6.0-pre.0",
+ "react-router": "6.11.0-pre.0"
},
"devDependencies": {
"react": "^18.2.0",
diff --git a/packages/react-router-native/CHANGELOG.md b/packages/react-router-native/CHANGELOG.md
index 324b2527b6..af19d074d2 100644
--- a/packages/react-router-native/CHANGELOG.md
+++ b/packages/react-router-native/CHANGELOG.md
@@ -1,5 +1,12 @@
# `react-router-native`
+## 6.11.0-pre.0
+
+### Patch Changes
+
+- Updated dependencies:
+ - `react-router@6.11.0-pre.0`
+
## 6.10.0
### Patch Changes
diff --git a/packages/react-router-native/package.json b/packages/react-router-native/package.json
index 25e6650077..b0d071f87a 100644
--- a/packages/react-router-native/package.json
+++ b/packages/react-router-native/package.json
@@ -1,6 +1,6 @@
{
"name": "react-router-native",
- "version": "6.10.0",
+ "version": "6.11.0-pre.0",
"description": "Declarative routing for React Native applications",
"keywords": [
"react",
@@ -22,7 +22,7 @@
"types": "./dist/index.d.ts",
"dependencies": {
"@ungap/url-search-params": "^0.1.4",
- "react-router": "6.10.0"
+ "react-router": "6.11.0-pre.0"
},
"devDependencies": {
"react": "^18.2.0",
diff --git a/packages/react-router/CHANGELOG.md b/packages/react-router/CHANGELOG.md
index 1cc40c125b..fcb1404c42 100644
--- a/packages/react-router/CHANGELOG.md
+++ b/packages/react-router/CHANGELOG.md
@@ -1,5 +1,19 @@
# `react-router`
+## 6.11.0-pre.0
+
+### Patch Changes
+
+- Log loader/action errors to the console in dev for easier stack trace evaluation ([#10286](https://github.com/remix-run/react-router/pull/10286))
+- Fix bug preventing rendering of descendant `` when `RouterProvider` errors existed ([#10374](https://github.com/remix-run/react-router/pull/10374))
+- Fix inadvertent re-renders when using `Component` instead of `element` on a route definition ([#10287](https://github.com/remix-run/react-router/pull/10287))
+- Fix detection of `useNavigate` in the render cycle by setting the `activeRef` in a layout effect, allowing the `navigate` function to be passed to child components and called in a `useEffect` there. ([#10394](https://github.com/remix-run/react-router/pull/10394))
+- Switched from `useSyncExternalStore` to `useState` for internal `@remix-run/router` router state syncing in ``. We found some [subtle bugs](https://codesandbox.io/s/use-sync-external-store-loop-9g7b81) where router state updates got propagated _before_ other normal `useState` updates, which could lead to footguns in `useEffect` calls. ([#10377](https://github.com/remix-run/react-router/pull/10377))
+- Allow `useRevalidator()` to resolve a loader-driven error boundary scenario ([#10369](https://github.com/remix-run/react-router/pull/10369))
+- When using a `RouterProvider`, `useNavigate`/`useSubmit`/`fetcher.submit` are now stable across location changes, since we can handle relative routing via the `@remix-run/router` instance and get rid of our dependence on `useLocation()`. When using `BrowserRouter`, these hooks remain unstable across location changes because they still rely on `useLocation()`. ([#10336](https://github.com/remix-run/react-router/pull/10336))
+- Updated dependencies:
+ - `@remix-run/router@1.6.0-pre.0`
+
## 6.10.0
### Minor Changes
diff --git a/packages/react-router/package.json b/packages/react-router/package.json
index 1ff5f17606..a2c3c6d1b3 100644
--- a/packages/react-router/package.json
+++ b/packages/react-router/package.json
@@ -1,6 +1,6 @@
{
"name": "react-router",
- "version": "6.10.0",
+ "version": "6.11.0-pre.0",
"description": "Declarative routing for React",
"keywords": [
"react",
@@ -23,7 +23,7 @@
"module": "./dist/index.js",
"types": "./dist/index.d.ts",
"dependencies": {
- "@remix-run/router": "1.5.0"
+ "@remix-run/router": "1.6.0-pre.0"
},
"devDependencies": {
"react": "^18.2.0"
diff --git a/packages/router/CHANGELOG.md b/packages/router/CHANGELOG.md
index a4b4db2311..019c923653 100644
--- a/packages/router/CHANGELOG.md
+++ b/packages/router/CHANGELOG.md
@@ -1,5 +1,26 @@
# `@remix-run/router`
+## 1.6.0-pre.0
+
+### Minor Changes
+
+- - Enable relative routing in the `@remix-run/router` when providing a source route ID from which the path is relative to: ([#10336](https://github.com/remix-run/react-router/pull/10336))
+
+ - Example: `router.navigate("../path", { fromRouteId: "some-route" })`.
+ - This also applies to `router.fetch` which already receives a source route ID
+
+ - Introduce a new `@remix-run/router` `future.v7_prependBasename` flag to enable `basename` prefixing to all paths coming into `router.navigate` and `router.fetch`.
+ - Previously the `basename` was prepended in the React Router layer, but now that relative routing is being handled by the router we need prepend the `basename` _after_ resolving any relative paths
+ - This also enables `basename` support in `useFetcher` as well
+
+### Patch Changes
+
+- Enhance `LoaderFunction`/`ActionFunction` return type to prevent `undefined` from being a valid return value ([#10267](https://github.com/remix-run/react-router/pull/10267))
+- Ensure proper 404 error on `fetcher.load` call to a route without a `loader` ([#10345](https://github.com/remix-run/react-router/pull/10345))
+- Deprecate the `createRouter` `detectErrorBoundary` option in favor of the new `mapRouteProperties` option for converting a framework-agnostic route to a framework-aware route. This allows us to set more than just the `hasErrorBoundary` property during route pre-processing, and is now used for mapping `Component -> element` and `ErrorBoundary -> errorElement` in `react-router`. ([#10287](https://github.com/remix-run/react-router/pull/10287))
+- Fixed a bug where fetchers were incorrectly attempting to revalidate on search params changes or routing to the same URL (using the same logic for route `loader` revalidations). However, since fetchers have a static href, they should only revalidate on `action` submissions or `router.revalidate` calls. ([#10344](https://github.com/remix-run/react-router/pull/10344))
+- Decouple `AbortController` usage between revalidating fetchers and the thing that triggered them such that the unmount/deletion of a revalidating fetcher doesn't impact the ongoing triggering navigation/revalidation ([#10271](https://github.com/remix-run/react-router/pull/10271))
+
## 1.5.0
### Minor Changes
diff --git a/packages/router/package.json b/packages/router/package.json
index f92ebfcfb6..54d7951d2a 100644
--- a/packages/router/package.json
+++ b/packages/router/package.json
@@ -1,6 +1,6 @@
{
"name": "@remix-run/router",
- "version": "1.5.0",
+ "version": "1.6.0-pre.0",
"description": "Nested/Data-driven/Framework-agnostic Routing",
"keywords": [
"remix",