mirror of
https://github.com/docmost/docmost.git
synced 2026-05-07 06:23:06 +08:00
d7a5fda53c
* feat: feature flag upgrade * fix translations * refactor * fix * fix
12 lines
362 B
TypeScript
12 lines
362 B
TypeScript
import { useQuery, UseQueryResult } from "@tanstack/react-query";
|
|
import { getEntitlements } from "./entitlement-service";
|
|
import { Entitlements } from "./entitlement.types";
|
|
|
|
export function useEntitlements(): UseQueryResult<Entitlements> {
|
|
return useQuery({
|
|
queryKey: ["entitlements"],
|
|
queryFn: getEntitlements,
|
|
staleTime: 5 * 60 * 1000,
|
|
});
|
|
}
|