query-key-factory icon indicating copy to clipboard operation
query-key-factory copied to clipboard

A library for creating typesafe standardized query keys, useful for cache management in @tanstack/query

Results 19 query-key-factory issues
Sort by recently updated
recently updated
newest added

This is just to initiate a discussion around supporting nested keys. @lukemorales have you seen trpc router examples https://trpc.io/docs/v9/merging-routers? It would be great if we could think about how to...

enhancement

This PR was opened by the [Changesets release](https://github.com/changesets/action) GitHub action. When you're ready to do a release, you can merge this and the packages will be published to npm automatically....

It would be nice to have a third level in the factory. For example if you have 5 different api urls with 30 endpoints underneed and not only a single...

enhancement

Hello! [This article](https://tkdodo.eu/blog/leveraging-the-query-function-context) from TkDodo's blog proposes a very convenient structure for query keys: they are arrays, they have only a single element and all the data, including some high-level...

enhancement
question

Hello, with React query i naturally have this scenario: -list of customers by account filtered by order by how i map this to cache keys is: `function customersByAccountId(accountId: number) {...

enhancement

There are quite a few problems you can see in the attached video using version 1.3.2 https://github.com/lukemorales/query-key-factory/assets/5176891/f8e863e8-455f-4f82-9718-16dbcd1689fe - code completion poup needs a few seconds to be shown (I hit...

bug
enhancement

Hi I'm trying to use `createQueryKeys` with `useInfiniteQuery` when use `ctx.pageParam` type error occurred Error Message ``` Property 'pageParam' does not exist on type '{ queryKey: QueryKey; signal: AbortSignal; meta:...

I have a rest api with lots of mutation and I would love to create a single store per model that combine both queries and mutations together:

bug
will be resolved in a major release

I first tried to follow the standard practice like for parametrized queries ```typescript export const todos = createMutationKeys('todos', { prop: (input: string) => ({ mutationKey: [input], mutationFn: () => Promise.resolve(input),...

bug
help wanted
will be resolved in a major release

Hi, I wanted to put up a feature request for support for TanStack Query v5 which makes `defaultPageParam` mandatory in `useInfiniteQuery` and exposes `pageParam` and `direction` in QueryFnContext. If there...

will be resolved in a major release