* chore(release): v5.1.0

* feat: implement resume thumbnails

* fix: remove unused mcp tools

* docs: fix formatting of docs
This commit is contained in:
Amruth Pillai
2026-05-07 15:12:33 +02:00
committed by GitHub
parent 51c366310e
commit 50ba37a27f
1015 changed files with 106087 additions and 141872 deletions
+38
View File
@@ -0,0 +1,38 @@
import { StandardRPCJsonSerializer } from "@orpc/client/standard";
import { MutationCache, QueryClient } from "@tanstack/react-query";
const serializer = new StandardRPCJsonSerializer();
export const getQueryClient = () => {
const queryClient = new QueryClient({
defaultOptions: {
queries: {
gcTime: 5 * 60 * 1000, // 5 minutes
staleTime: 60 * 1000, // 1 minute
queryKeyHashFn(queryKey) {
const [json, meta] = serializer.serialize(queryKey);
return JSON.stringify({ json, meta });
},
},
dehydrate: {
serializeData(data) {
const [json, meta] = serializer.serialize(data);
return { json, meta };
},
},
hydrate: {
deserializeData(data) {
return serializer.deserialize(data.json, data.meta);
},
},
},
mutationCache: new MutationCache({
onSettled: (_1, _2, _3, _4, _5, context) => {
if (context?.meta?.noInvalidate) return;
void queryClient.invalidateQueries();
},
}),
});
return queryClient;
};