MCPcopy Create free account
hub / github.com/TanStack/query / CommonOptions

Interface CommonOptions

packages/vue-query/src/vueQueryPlugin.ts:10–25  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

8type ClientPersister = (client: QueryClient) => [() => void, Promise<void>]
9
10interface CommonOptions {
11 /** Enables the legacy Vue Devtools v6 plugin panel. Prefer `@tanstack/vue-query-devtools` for Vue 3 apps. */
12 enableDevtoolsV6Plugin?: boolean
13 /**
14 * Distinguishes multiple `QueryClient`s provided in the same app — pass the same key to `useQueryClient` to
15 * pick this one. Only needed when installing more than one client.
16 */
17 queryClientKey?: string
18 /**
19 * Restores a persisted cache before the app mounts. While it runs, `queryClient.isRestoring` is `true`, which
20 * suppresses fetches — see `usePersistQueryClient` in `@tanstack/query-persist-client-core` for building one.
21 */
22 clientPersister?: ClientPersister
23 /** Called once `clientPersister`'s returned promise resolves and the cache has finished restoring. */
24 clientPersisterOnSuccess?: (client: QueryClient) => void
25}
26
27interface ConfigOptions extends CommonOptions {
28 /** Options for the `QueryClient` the plugin constructs. Ignored if `queryClient` is also set. */

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected