You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
description: Data Client 0.9 brings Collections for automatic list management, improved DevTools experience, and removes legacy APIs for a cleaner, faster library.
4
+
tags: [releases, rest, resource, endpoint]
5
+
description: Data Client 0.9 brings improved DevTools experience, Resource.extend() for customization, new controller methods, and removes legacy APIs for a cleaner, faster library.
6
6
---
7
7
8
8
import Link from '@docusaurus/Link';
9
9
10
-
[Collections](/rest/api/Collection) are the highlight of this release - automatically managing list updates when
11
-
creating, updating, or deleting entities. Combined with [Resource.extend()](/rest/api/resource#extend),
12
-
building CRUD operations has never been simpler.
10
+
This release focuses on developer experience with a [devtools button](/blog/2024/01/15/v0.9-release-announcement#devtools-button) that appears in development
11
+
mode, better [DevTools history](/blog/2024/01/15/v0.9-release-announcement#devtools-improvements), and new controller methods like
12
+
[controller.expireAll()](/blog/2024/01/15/v0.9-release-announcement#controllerexpireall) and [controller.fetchIfStale()](/blog/2024/01/15/v0.9-release-announcement#controllerfetchifstale).
13
+
14
+
[Resource.extend()](/rest/api/resource#extend) provides three powerful ways to customize resources - adding new endpoints,
15
+
overriding existing ones, or deriving from base endpoints.
13
16
14
17
```ts
15
-
const TodoResource =createResource({
16
-
path: '/todos/:id',
17
-
schema: Todo,
18
+
const UserResource =createResource({
19
+
path: '/users/:id',
20
+
schema: User,
21
+
}).extend('current', {
22
+
path: '/users/current',
18
23
});
19
-
// POST /todos - automatically adds to all matching collections
20
-
ctrl.fetch(TodoResource.getList.push, { title: 'My new todo', userId });
21
24
```
22
25
23
-
We've also improved the developer experience with a [devtools button](/blog/2024/01/15/v0.9-release-announcement#devtools-button) that appears in development
24
-
mode, better [DevTools history](/blog/2024/01/15/v0.9-release-announcement#devtools-improvements), and new controller methods like
25
-
[controller.expireAll()](/blog/2024/01/15/v0.9-release-announcement#controllerexpireall) and [controller.fetchIfStale()](/blog/2024/01/15/v0.9-release-announcement#controllerfetchifstale).
- Add `className` to ErrorBoundary and `errorClassName` to [AsyncBoundary](/docs/api/AsyncBoundary)[#2785](https://github.com/reactive/data-client/pull/2785)
204
183
- New `getDefaultManagers()` export for explicit manager control [#2791](https://github.com/reactive/data-client/pull/2791)
205
184
- Replace BackupBoundary with UniversalSuspense + BackupLoading [#2803](https://github.com/reactive/data-client/pull/2803)
206
-
- Entity.process() receives endpoint `args` as fourth parameter [a8936f5](https://github.com/reactive/data-client/commit/a8936f5e6d)
207
-
-`nonFilterArgumentKeys` for Collection to exclude sort/order params from filtering [318df89](https://github.com/reactive/data-client/commit/318df89bf7)
208
-
- Support `+` and `*` modifiers in [RestEndpoint.path](/rest/api/RestEndpoint#path)[a6b4f4a](https://github.com/reactive/data-client/commit/a6b4f4aabbfd06f5106a96e809a6c1a5e7045172)
209
-
- Support `{}` grouping in path for optional segments [a6b4f4a](https://github.com/reactive/data-client/commit/a6b4f4aabbfd06f5106a96e809a6c1a5e7045172)
185
+
- Entity.process() receives endpoint `args` as fourth parameter *(since 0.7)*[a8936f5](https://github.com/reactive/data-client/commit/a8936f5e6d)
186
+
-`nonFilterArgumentKeys` for Collection to exclude sort/order params from filtering *(since 0.7)*[318df89](https://github.com/reactive/data-client/commit/318df89bf7)
As usual, if you have any troubles or questions, feel free to join our [](https://discord.gg/wXGV27xm6t) or [file a bug](https://github.com/reactive/data-client/issues/new/choose)
0 commit comments