Skip to content

The recommended client-preset feels subjectively worse than previous solutions #8773

Discussion options

You must be logged in to vote

Hey @ChristianIvicevic.

As you mentioned your concerns are primarily related to the dedicated react-query plugin.

I can understand that this change takes some of the convenience you had previously when generating dedicated hooks for each GraphQL operation.
On the other hand, it makes this library more straightforward to use for different client libraries without having to maintain an almost infinite variation of plugins, of which most of them only a small fraction of people use.

As you mentioned a solution could be to write your own small wrapper react hook:

import type { TypedDocumentNode } from "@graphql-typed-document-node/core";
import { useQuery } from "@tanstack/react-query";
import { 

Replies: 1 comment

Comment options

You must be logged in to vote
0 replies
Answer selected by n1ru4l
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
2 participants