We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 6bc45b8 commit fba2c86Copy full SHA for fba2c86
examples/react/optimistic-updates-cache/src/pages/index.tsx
@@ -20,8 +20,8 @@ type Todos = {
20
ts: number
21
}
22
23
-async function fetchTodos(): Promise<Todos> {
24
- const response = await fetch('/api/data')
+async function fetchTodos({ signal }: { signal: AbortSignal }): Promise<Todos> {
+ const response = await fetch('/api/data', { signal })
25
return await response.json()
26
27
0 commit comments