@@ -13,154 +13,161 @@ We manage release notes in this file instead of the paginated Github Releases Pa
13
13
<summary >Table of Contents</summary >
14
14
15
15
- [ React Router Releases] ( #react-router-releases )
16
- - [ v6.23.1] ( #v6231 )
16
+ - [ v6.24.0] ( #v6240 )
17
+ - [ What's Changed] ( #whats-changed )
18
+ - [ Lazy Route Discovery (a.k.a. Fog of War)] ( #lazy-route-discovery-aka-fog-of-war )
19
+ - [ Minor Changes] ( #minor-changes )
17
20
- [ Patch Changes] ( #patch-changes )
21
+ - [ v6.23.1] ( #v6231 )
22
+ - [ Patch Changes] ( #patch-changes-1 )
18
23
- [ v6.23.0] ( #v6230 )
19
- - [ What's Changed] ( #whats-changed )
24
+ - [ What's Changed] ( #whats-changed-1 )
20
25
- [ Data Strategy (unstable)] ( #data-strategy-unstable )
21
26
- [ Skip Action Error Revalidation (unstable)] ( #skip-action-error-revalidation-unstable )
22
- - [ Minor Changes] ( #minor-changes )
27
+ - [ Minor Changes] ( #minor-changes-1 )
23
28
- [ v6.22.3] ( #v6223 )
24
- - [ Patch Changes] ( #patch-changes-1 )
25
- - [ v6.22.2] ( #v6222 )
26
29
- [ Patch Changes] ( #patch-changes-2 )
27
- - [ v6.22.1 ] ( #v6221 )
30
+ - [ v6.22.2 ] ( #v6222 )
28
31
- [ Patch Changes] ( #patch-changes-3 )
32
+ - [ v6.22.1] ( #v6221 )
33
+ - [ Patch Changes] ( #patch-changes-4 )
29
34
- [ v6.22.0] ( #v6220 )
30
- - [ What's Changed] ( #whats-changed-1 )
35
+ - [ What's Changed] ( #whats-changed-2 )
31
36
- [ Core Web Vitals Technology Report Flag] ( #core-web-vitals-technology-report-flag )
32
- - [ Minor Changes] ( #minor-changes-1 )
33
- - [ Patch Changes] ( #patch-changes-4 )
34
- - [ v6.21.3] ( #v6213 )
37
+ - [ Minor Changes] ( #minor-changes-2 )
35
38
- [ Patch Changes] ( #patch-changes-5 )
36
- - [ v6.21.2 ] ( #v6212 )
39
+ - [ v6.21.3 ] ( #v6213 )
37
40
- [ Patch Changes] ( #patch-changes-6 )
38
- - [ v6.21.1 ] ( #v6211 )
41
+ - [ v6.21.2 ] ( #v6212 )
39
42
- [ Patch Changes] ( #patch-changes-7 )
43
+ - [ v6.21.1] ( #v6211 )
44
+ - [ Patch Changes] ( #patch-changes-8 )
40
45
- [ v6.21.0] ( #v6210 )
41
- - [ What's Changed] ( #whats-changed-2 )
46
+ - [ What's Changed] ( #whats-changed-3 )
42
47
- [ ` future.v7_relativeSplatPath ` ] ( #futurev7_relativesplatpath )
43
48
- [ Partial Hydration] ( #partial-hydration )
44
- - [ Minor Changes] ( #minor-changes-2 )
45
- - [ Patch Changes] ( #patch-changes-8 )
46
- - [ v6.20.1] ( #v6201 )
47
- - [ Patch Changes] ( #patch-changes-9 )
48
- - [ v6.20.0] ( #v6200 )
49
49
- [ Minor Changes] ( #minor-changes-3 )
50
+ - [ Patch Changes] ( #patch-changes-9 )
51
+ - [ v6.20.1] ( #v6201 )
50
52
- [ Patch Changes] ( #patch-changes-10 )
51
- - [ v6.19.0] ( #v6190 )
52
- - [ What's Changed] ( #whats-changed-3 )
53
- - [ ` unstable_flushSync ` API] ( #unstable_flushsync-api )
53
+ - [ v6.20.0] ( #v6200 )
54
54
- [ Minor Changes] ( #minor-changes-4 )
55
55
- [ Patch Changes] ( #patch-changes-11 )
56
- - [ v6.18 .0] ( #v6180 )
56
+ - [ v6.19 .0] ( #v6190 )
57
57
- [ What's Changed] ( #whats-changed-4 )
58
- - [ New Fetcher APIs] ( #new-fetcher-apis )
59
- - [ Persistence Future Flag (` future.v7_fetcherPersist ` )] ( #persistence-future-flag-futurev7_fetcherpersist )
58
+ - [ ` unstable_flushSync ` API] ( #unstable_flushsync-api )
60
59
- [ Minor Changes] ( #minor-changes-5 )
61
60
- [ Patch Changes] ( #patch-changes-12 )
62
- - [ v6.17 .0] ( #v6170 )
61
+ - [ v6.18 .0] ( #v6180 )
63
62
- [ What's Changed] ( #whats-changed-5 )
64
- - [ View Transitions 🚀] ( #view-transitions- )
63
+ - [ New Fetcher APIs] ( #new-fetcher-apis )
64
+ - [ Persistence Future Flag (` future.v7_fetcherPersist ` )] ( #persistence-future-flag-futurev7_fetcherpersist )
65
65
- [ Minor Changes] ( #minor-changes-6 )
66
66
- [ Patch Changes] ( #patch-changes-13 )
67
- - [ v6.16.0] ( #v6160 )
67
+ - [ v6.17.0] ( #v6170 )
68
+ - [ What's Changed] ( #whats-changed-6 )
69
+ - [ View Transitions 🚀] ( #view-transitions- )
68
70
- [ Minor Changes] ( #minor-changes-7 )
69
71
- [ Patch Changes] ( #patch-changes-14 )
70
- - [ v6.15 .0] ( #v6150 )
72
+ - [ v6.16 .0] ( #v6160 )
71
73
- [ Minor Changes] ( #minor-changes-8 )
72
74
- [ Patch Changes] ( #patch-changes-15 )
73
- - [ v6.14.2] ( #v6142 )
75
+ - [ v6.15.0] ( #v6150 )
76
+ - [ Minor Changes] ( #minor-changes-9 )
74
77
- [ Patch Changes] ( #patch-changes-16 )
75
- - [ v6.14.1 ] ( #v6141 )
78
+ - [ v6.14.2 ] ( #v6142 )
76
79
- [ Patch Changes] ( #patch-changes-17 )
77
- - [ v6.14.0] ( #v6140 )
78
- - [ What's Changed] ( #whats-changed-6 )
79
- - [ JSON/Text Submissions] ( #jsontext-submissions )
80
- - [ Minor Changes] ( #minor-changes-9 )
80
+ - [ v6.14.1] ( #v6141 )
81
81
- [ Patch Changes] ( #patch-changes-18 )
82
- - [ v6.13 .0] ( #v6130 )
82
+ - [ v6.14 .0] ( #v6140 )
83
83
- [ What's Changed] ( #whats-changed-7 )
84
+ - [ JSON/Text Submissions] ( #jsontext-submissions )
84
85
- [ Minor Changes] ( #minor-changes-10 )
85
86
- [ Patch Changes] ( #patch-changes-19 )
86
- - [ v6.12.1] ( #v6121 )
87
- - [ Patch Changes] ( #patch-changes-20 )
88
- - [ v6.12.0] ( #v6120 )
87
+ - [ v6.13.0] ( #v6130 )
89
88
- [ What's Changed] ( #whats-changed-8 )
90
- - [ ` React.startTransition ` support ] ( #reactstarttransition-support )
89
+ - [ v7_startTransition ] ( #v7_starttransition )
91
90
- [ Minor Changes] ( #minor-changes-11 )
91
+ - [ Patch Changes] ( #patch-changes-20 )
92
+ - [ v6.12.1] ( #v6121 )
92
93
- [ Patch Changes] ( #patch-changes-21 )
93
- - [ v6.11.2] ( #v6112 )
94
+ - [ v6.12.0] ( #v6120 )
95
+ - [ What's Changed] ( #whats-changed-9 )
96
+ - [ ` React.startTransition ` support] ( #reactstarttransition-support )
97
+ - [ Minor Changes] ( #minor-changes-12 )
94
98
- [ Patch Changes] ( #patch-changes-22 )
95
- - [ v6.11.1 ] ( #v6111 )
99
+ - [ v6.11.2 ] ( #v6112 )
96
100
- [ Patch Changes] ( #patch-changes-23 )
97
- - [ v6.11.0] ( #v6110 )
98
- - [ Minor Changes] ( #minor-changes-12 )
101
+ - [ v6.11.1] ( #v6111 )
99
102
- [ Patch Changes] ( #patch-changes-24 )
100
- - [ v6.10.0] ( #v6100 )
101
- - [ What's Changed] ( #whats-changed-9 )
103
+ - [ v6.11.0] ( #v6110 )
102
104
- [ Minor Changes] ( #minor-changes-13 )
103
105
- [ Patch Changes] ( #patch-changes-25 )
104
- - [ v6.9 .0] ( #v690 )
106
+ - [ v6.10 .0] ( #v6100 )
105
107
- [ What's Changed] ( #whats-changed-10 )
106
- - [ ` Component ` /` ErrorBoundary ` route properties] ( #componenterrorboundary-route-properties )
107
- - [ Introducing Lazy Route Modules] ( #introducing-lazy-route-modules )
108
108
- [ Minor Changes] ( #minor-changes-14 )
109
+ - [ future.v7_normalizeFormMethod] ( #futurev7_normalizeformmethod )
109
110
- [ Patch Changes] ( #patch-changes-26 )
110
- - [ v6.8.2] ( #v682 )
111
+ - [ v6.9.0] ( #v690 )
112
+ - [ What's Changed] ( #whats-changed-11 )
113
+ - [ ` Component ` /` ErrorBoundary ` route properties] ( #componenterrorboundary-route-properties )
114
+ - [ Introducing Lazy Route Modules] ( #introducing-lazy-route-modules )
115
+ - [ Minor Changes] ( #minor-changes-15 )
111
116
- [ Patch Changes] ( #patch-changes-27 )
112
- - [ v6.8.1 ] ( #v681 )
117
+ - [ v6.8.2 ] ( #v682 )
113
118
- [ Patch Changes] ( #patch-changes-28 )
114
- - [ v6.8.0] ( #v680 )
115
- - [ Minor Changes] ( #minor-changes-15 )
119
+ - [ v6.8.1] ( #v681 )
116
120
- [ Patch Changes] ( #patch-changes-29 )
117
- - [ v6.7 .0] ( #v670 )
121
+ - [ v6.8 .0] ( #v680 )
118
122
- [ Minor Changes] ( #minor-changes-16 )
119
123
- [ Patch Changes] ( #patch-changes-30 )
120
- - [ v6.6.2] ( #v662 )
124
+ - [ v6.7.0] ( #v670 )
125
+ - [ Minor Changes] ( #minor-changes-17 )
121
126
- [ Patch Changes] ( #patch-changes-31 )
122
- - [ v6.6.1 ] ( #v661 )
127
+ - [ v6.6.2 ] ( #v662 )
123
128
- [ Patch Changes] ( #patch-changes-32 )
124
- - [ v6.6.0] ( #v660 )
125
- - [ What's Changed] ( #whats-changed-11 )
126
- - [ Minor Changes] ( #minor-changes-17 )
129
+ - [ v6.6.1] ( #v661 )
127
130
- [ Patch Changes] ( #patch-changes-33 )
128
- - [ v6.5 .0] ( #v650 )
131
+ - [ v6.6 .0] ( #v660 )
129
132
- [ What's Changed] ( #whats-changed-12 )
130
133
- [ Minor Changes] ( #minor-changes-18 )
131
134
- [ Patch Changes] ( #patch-changes-34 )
132
- - [ v6.4.5] ( #v645 )
135
+ - [ v6.5.0] ( #v650 )
136
+ - [ What's Changed] ( #whats-changed-13 )
137
+ - [ Minor Changes] ( #minor-changes-19 )
133
138
- [ Patch Changes] ( #patch-changes-35 )
134
- - [ v6.4.4 ] ( #v644 )
139
+ - [ v6.4.5 ] ( #v645 )
135
140
- [ Patch Changes] ( #patch-changes-36 )
136
- - [ v6.4.3 ] ( #v643 )
141
+ - [ v6.4.4 ] ( #v644 )
137
142
- [ Patch Changes] ( #patch-changes-37 )
138
- - [ v6.4.2 ] ( #v642 )
143
+ - [ v6.4.3 ] ( #v643 )
139
144
- [ Patch Changes] ( #patch-changes-38 )
140
- - [ v6.4.1 ] ( #v641 )
145
+ - [ v6.4.2 ] ( #v642 )
141
146
- [ Patch Changes] ( #patch-changes-39 )
147
+ - [ v6.4.1] ( #v641 )
148
+ - [ Patch Changes] ( #patch-changes-40 )
142
149
- [ v6.4.0] ( #v640 )
143
- - [ What's Changed] ( #whats-changed-13 )
150
+ - [ What's Changed] ( #whats-changed-14 )
144
151
- [ Remix Data APIs] ( #remix-data-apis )
145
- - [ Patch Changes] ( #patch-changes-40 )
152
+ - [ Patch Changes] ( #patch-changes-41 )
146
153
- [ v6.3.0] ( #v630 )
147
- - [ Minor Changes] ( #minor-changes-19 )
154
+ - [ Minor Changes] ( #minor-changes-20 )
148
155
- [ v6.2.2] ( #v622 )
149
- - [ Patch Changes] ( #patch-changes-41 )
150
- - [ v6.2.1] ( #v621 )
151
156
- [ Patch Changes] ( #patch-changes-42 )
152
- - [ v6.2.0] ( #v620 )
153
- - [ Minor Changes] ( #minor-changes-20 )
157
+ - [ v6.2.1] ( #v621 )
154
158
- [ Patch Changes] ( #patch-changes-43 )
155
- - [ v6.1.1] ( #v611 )
156
- - [ Patch Changes] ( #patch-changes-44 )
157
- - [ v6.1.0] ( #v610 )
159
+ - [ v6.2.0] ( #v620 )
158
160
- [ Minor Changes] ( #minor-changes-21 )
161
+ - [ Patch Changes] ( #patch-changes-44 )
162
+ - [ v6.1.1] ( #v611 )
159
163
- [ Patch Changes] ( #patch-changes-45 )
160
- - [ v6.0.2] ( #v602 )
164
+ - [ v6.1.0] ( #v610 )
165
+ - [ Minor Changes] ( #minor-changes-22 )
161
166
- [ Patch Changes] ( #patch-changes-46 )
162
- - [ v6.0.1 ] ( #v601 )
167
+ - [ v6.0.2 ] ( #v602 )
163
168
- [ Patch Changes] ( #patch-changes-47 )
169
+ - [ v6.0.1] ( #v601 )
170
+ - [ Patch Changes] ( #patch-changes-48 )
164
171
- [ v6.0.0] ( #v600 )
165
172
166
173
</details >
@@ -184,6 +191,53 @@ Date: YYYY-MM-DD
184
191
**Full Changelog**: [`v6.X.Y...v6.X.Y`](https://github.com/remix-run/react-router/compare/[email protected] @6.X.Y)
185
192
-->
186
193
194
+ ## v6.24.0
195
+
196
+ Date: 2024-07-18
197
+
198
+ ### What's Changed
199
+
200
+ #### Lazy Route Discovery (a.k.a. Fog of War)
201
+
202
+ We're really excited to release our new API for "Lazy Route Discovery" in v6.24.0! For some background information, please check out the original [ RFC] ( https://github.com/remix-run/react-router/discussions/11113 ) . The tl;dr; is that ever since we introduced the Data APIs in v6.4 via ` <RouterProvider> ` , we've been a little bummed that one of the tradeoffs was the lack of a compelling code-splitting story mirroring what we had in the ` <BrowserRouter> ` /` <Routes> ` apps. We took a baby-step towards improving that story with ` route.lazy ` in v6.9, but with v6.24 we've gone the rest of the way.
203
+
204
+ With 6.24, you can now load portions of the route tree lazily via the new ` unstable_patchRoutesOnMiss ` option passed to ` createBrowserRouter ` (and it's memory/hash counterparts). This gives you a way to hook into spots where React Router is unable to match a given path and patch new routes into the route tree during the navigation (or fetcher call).
205
+
206
+ Here's a very small example, but please refer to the [ documentation] ( https://reactrouter.com/en/main/routers/create-browser-router#unstable_patchroutesonmiss ) for more information and use cases:
207
+
208
+ ``` js
209
+ const router = createBrowserRouter (
210
+ [
211
+ {
212
+ id: " root" ,
213
+ path: " /" ,
214
+ Component: RootComponent,
215
+ },
216
+ ],
217
+ {
218
+ async unstable_patchRoutesOnMiss ({ path, patch }) {
219
+ if (path === " /a" ) {
220
+ // Load the `a` route (`{ path: 'a', Component: A }`)
221
+ let route = await getARoute ();
222
+ // Patch the `a` route in as a new child of the `root` route
223
+ patch (" root" , [route]);
224
+ }
225
+ },
226
+ }
227
+ );
228
+ ```
229
+
230
+ ### Minor Changes
231
+
232
+ - Add support for Lazy Route Discovery (a.k.a. Fog of War) ([ #11626 ] ( https://github.com/remix-run/react-router/pull/11626 ) )
233
+
234
+ ### Patch Changes
235
+
236
+ - Fix ` fetcher.submit ` types - remove incorrect ` navigate ` /` fetcherKey ` /` unstable_viewTransition ` options because they are only relevant for ` useSubmit ` ([ #11631 ] ( https://github.com/remix-run/react-router/pull/11631 ) )
237
+ - Allow falsy ` location.state ` values passed to ` <StaticRouter> ` ([ #11495 ] ( https://github.com/remix-run/react-router/pull/11495 ) )
238
+
239
+ ** Full Changelog
** :
[ ` v6.23.1...v6.24.0 ` ] ( https://github.com/remix-run/react-router/compare/[email protected] @6.24.0 )
240
+
187
241
## v6.23.1
188
242
189
243
Date: 2024-05-10
0 commit comments