0
Fork 0
mirror of https://github.com/TanStack/query.git synced 2026-11-16 22:50:20 +00:00
query/docs/framework/lit/reference/interfaces/Register.md
Wonsuk Choi f38e6271b4
chore(*): update '@tanstack/typedoc-config' to v0.3.5 (#12035)
* chore(scripts/generate-docs): read type alias bodies whose type parameters have defaults

* chore(*): update '@tanstack/typedoc-config' to v0.3.5
2026-10-17 11:14:03 +09:00

1.2 KiB

id title
Register Register

Defined in: packages/query-core/src/types.ts:71

The interface to augment via declaration merging to override Query's default types repository-wide. Each field it declares replaces the default of the matching type: defaultError for DefaultError, queryKey for QueryKey, mutationKey for MutationKey, queryMeta for QueryMeta and mutationMeta for MutationMeta. Leave a field out to keep that type's default. Augment the module you install — @tanstack/react-query, @tanstack/vue-query, @tanstack/solid-query, @tanstack/svelte-query, @tanstack/preact-query, @tanstack/angular-query-experimental or @tanstack/lit-query. Augmenting @tanstack/query-core works too and covers every adapter at once.

Example

// Use the module you installed — here, the React adapter.
declare module '@tanstack/react-query' {
  interface Register {
    defaultError: AxiosError
  }
}