Skip to content

Commit 8cf5bce

Browse files
committed
docs: Update homepage meta description
1 parent 6a8a442 commit 8cf5bce

File tree

5 files changed

+20
-15
lines changed

5 files changed

+20
-15
lines changed

docs/core/api/Manager.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ import TypeScriptEditor from '@site/src/components/TypeScriptEditor';
1515

1616
# Manager
1717

18-
`Managers` are singletons that handle global side-effects. Kind of like `useEffect()` for the central data
18+
`Managers` are singletons that handle global side-effects. Kind of like [useEffect()](https://react.dev/reference/react/useEffect) for the central data
1919
store.
2020

2121
The default managers orchestrate the complex asynchronous behavior that <abbr title="Reactive Data Client">Data Client</abbr>

docs/rest/guides/auth.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -54,6 +54,8 @@ MyResource.get({ id: 1 });
5454

5555
</EndpointPlayground>
5656

57+
See [Django Integration](./django.md) for an example that also includes [CSRF protection](https://docs.djangoproject.com/en/5.0/howto/csrf/#using-csrf-protection-with-ajax).
58+
5759
## Access Tokens or JWT
5860

5961
<Tabs

docs/rest/guides/computed-properties.md

Lines changed: 0 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -26,9 +26,6 @@ class User extends Entity {
2626
}
2727
// highlight-end
2828

29-
pk() {
30-
return this.id;
31-
}
3229
static key = 'User';
3330
}
3431
```
@@ -63,9 +60,6 @@ class User extends Entity {
6360
createdAt = Temporal.Instant.fromEpochSeconds(0);
6461
lifetimeBlinkCount = BigNumber(0);
6562

66-
pk() {
67-
return this.id;
68-
}
6963
static key = 'User';
7064

7165
// highlight-start
@@ -102,9 +96,6 @@ export class User extends Entity {
10296
id = '';
10397
name = '';
10498
isAdmin = false;
105-
pk() {
106-
return this.id;
107-
}
10899
}
109100
export const UserResource = resource({
110101
path: '/users/:id',

docs/rest/guides/side-effects.md

Lines changed: 16 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ When mutations update more than one resource, it may be tempting to simply
66
[expire all](/docs/api/Controller#expireAll) the other resources.
77

88
However, we can still achieve the high performance atomic mutations if we
9-
simply bundle *all* updated resources in the mutation response, we can
9+
simply bundle _all_ updated resources in the mutation response, we can
1010
avoid this slow networking cascade.
1111

1212
<div style={{display: 'grid', gridTemplateColumns: '1fr 1fr', columnGap: '15px'}}>
@@ -27,6 +27,7 @@ sequenceDiagram
2727
Note over Client,Server: Lookup Account
2828
Server->>Client: Account
2929
```
30+
3031
</div>
3132
<div>
3233
<h4 style={{textAlign: 'center'}}><img src="https://dataclient.io/img/client-logo.svg" width="20" height="20" style={{marginBottom: '-4px',marginRight: '4px'}} /> Response Bundling</h4>
@@ -40,6 +41,7 @@ sequenceDiagram
4041
Note over Client,Server: Backend performs trade
4142
Server->>Client: Trade + Account
4243
```
44+
4345
</div>
4446

4547
</div>
@@ -73,8 +75,17 @@ created.
7375
To handle this, we just need to update the `schema` to include the custom
7476
endpoint.
7577

76-
```typescript title="resources/TradeResource.ts"
77-
import { resource } from '@data-client/rest';
78+
```typescript title="resources/Trade.ts"
79+
import { resource, Entity } from '@data-client/rest';
80+
import { Account } from './Account';
81+
82+
export class Trade extends Entity {
83+
id = 0;
84+
user = 0;
85+
amount = '0';
86+
coin = '';
87+
created_at = '';
88+
}
7889

7990
export const TradeResource = resource({
8091
path: '/trade/:id',
@@ -96,7 +107,8 @@ be updated in the cache after the `POST` request is complete.
96107
```typescript title="CreateTrade.tsx"
97108
export default function CreateTrade() {
98109
const ctrl = useController();
99-
const handleSubmit = payload => ctrl.fetch(TradeResource.create, payload);
110+
const handleSubmit = payload =>
111+
ctrl.fetch(TradeResource.create, payload);
100112
//...
101113
}
102114
```

website/src/pages/index.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -98,7 +98,7 @@ function HomepageEnder() {
9898
export default function Home() {
9999
const image = useBaseUrl('img/social/data_client_logo_card.png');
100100
return (
101-
<Layout description="Async State Management without the Management.">
101+
<Layout description="The scalable way to build applications with dynamic data. REST, GraphQL, Websockets+SSE with React, NextJS, React Native, ExpoGo">
102102
<PageMetadata image={image} />
103103
<Head>
104104
<title>The Reactive Data Client</title>

0 commit comments

Comments
 (0)