Skip to content
This repository has been archived by the owner on Apr 6, 2023. It is now read-only.

docs: add note about fetching data on initial load #7120

Merged
merged 3 commits into from
Sep 3, 2022
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Merge branch 'main' into docs/client-data-fetching-note
  • Loading branch information
pi0 authored Sep 3, 2022
commit dfc5db4565b1b116202bd1a0e2a6052f15c2e253
3 changes: 1 addition & 2 deletions docs/content/3.api/1.composables/use-fetch.md
Original file line number Diff line number Diff line change
Expand Up @@ -44,8 +44,7 @@ type AsyncData<DataT> = {
* `headers`: Request headers.
* `baseURL`: Base URL for the request.
* **Options (from `useAsyncData`)**:
* `key`: a unique key to ensure that data fetching can be properly de-duplicated across requests, if not provided, it will be generated based on the `url` and fetch options.
* `lazy`: Whether to resolve the async function after loading the route, instead of blocking client-side navigation (defaults to `false`).
* `key`: a unique key to ensure that data fetching can be properly de-duplicated across requests, if not provided, it will be generated based on the static code location where `useAyncData` is used.
* `server`: Whether to fetch the data on the server (defaults to `true`).
* `default`: A factory function to set the default value of the data, before the async function resolves - particularly useful with the `lazy: true` option.
* `pick`: Only pick specified keys in this array from the `handler` function result.
Expand Down
You are viewing a condensed version of this merge commit. You can view the full changes here.