UNPKG

2.17 kBMarkdownView Raw
1# `react-router`
2
3## 6.4.4
4
5### Patch Changes
6
7- Updated dependencies:
8 - `@remix-run/router@1.0.4`
9
10## 6.4.3
11
12### Patch Changes
13
14- `useRoutes` should be able to return `null` when passing `locationArg` ([#9485](https://github.com/remix-run/react-router/pull/9485))
15- fix `initialEntries` type in `createMemoryRouter` ([#9498](https://github.com/remix-run/react-router/pull/9498))
16- Updated dependencies:
17 - `@remix-run/router@1.0.3`
18
19## 6.4.2
20
21### Patch Changes
22
23- Fix `IndexRouteObject` and `NonIndexRouteObject` types to make `hasErrorElement` optional ([#9394](https://github.com/remix-run/react-router/pull/9394))
24- Enhance console error messages for invalid usage of data router hooks ([#9311](https://github.com/remix-run/react-router/pull/9311))
25- If an index route has children, it will result in a runtime error. We have strengthened our `RouteObject`/`RouteProps` types to surface the error in TypeScript. ([#9366](https://github.com/remix-run/react-router/pull/9366))
26- Updated dependencies:
27 - `@remix-run/router@1.0.2`
28
29## 6.4.1
30
31### Patch Changes
32
33- Preserve state from `initialEntries` ([#9288](https://github.com/remix-run/react-router/pull/9288))
34- Updated dependencies:
35 - `@remix-run/router@1.0.1`
36
37## 6.4.0
38
39Whoa this is a big one! `6.4.0` brings all the data loading and mutation APIs over from Remix. Here's a quick high level overview, but it's recommended you go check out the [docs][rr-docs], especially the [feature overview][rr-feature-overview] and the [tutorial][rr-tutorial].
40
41**New APIs**
42
43- Create your router with `createMemoryRouter`
44- Render your router with `<RouterProvider>`
45- Load data with a Route `loader` and mutate with a Route `action`
46- Handle errors with Route `errorElement`
47- Defer non-critical data with `defer` and `Await`
48
49**Bug Fixes**
50
51- Path resolution is now trailing slash agnostic (#8861)
52- `useLocation` returns the scoped location inside a `<Routes location>` component (#9094)
53
54**Updated Dependencies**
55
56- `@remix-run/router@1.0.0`
57
58[rr-docs]: https://reactrouter.com/
59[rr-feature-overview]: https://reactrouter.com/en/6.4.0/start/overview
60[rr-tutorial]: https://reactrouter.com/en/6.4.0/start/tutorial