Skip to content

Commit 638d492

Browse files
committed
update: README
1 parent 48228f8 commit 638d492

File tree

1 file changed

+18
-0
lines changed

1 file changed

+18
-0
lines changed

README.md

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -294,6 +294,24 @@ const writeClient = createClient({
294294
})
295295
```
296296
297+
### Next.js App Router
298+
299+
You can now use the fetch option of the Next.js App Router as CustomRequestInit.
300+
Please refer to the official Next.js documentation as the available options depend on the Next.js Type file.
301+
302+
[Functions: fetch \| Next\.js](https://nextjs.org/docs/app/api-reference/functions/fetch)
303+
304+
```ts
305+
const response = await client.getList({
306+
customRequestInit: {
307+
next: {
308+
revalidate: 60,
309+
},
310+
},
311+
endpoint: "endpoint",
312+
});
313+
```
314+
297315
# LICENSE
298316
299317
Apache-2.0

0 commit comments

Comments
 (0)