UNPKG

autumn-js

Version:

Autumn JS Library

34 lines (31 loc) 1.06 kB
import { A as AutumnError } from '../error-CG2LXoa7.js'; import { E as Entity } from '../entTypes-BbIk0Toa.js'; import { GetEntityParams } from '../client/types/clientEntTypes.js'; import { A as AutumnClient } from '../ReactAutumnClient-DNcV0gAT.js'; import '../cusTypes-Cf-s9PYP.js'; import '../client/types/clientReferralTypes.js'; import '../client/types/clientGenTypes.js'; import '../response-B1KyqUB9.js'; interface EntityProvider { entity: Entity | null; isLoading: boolean; error: AutumnError | null; refetch: (args: { entityId?: string; params?: GetEntityParams; }) => Promise<void>; lastParams: GetEntityParams | null; } declare const useEntityProvider: ({ client }: { client: AutumnClient; }) => { entity: Entity | null; isLoading: boolean; error: AutumnError | null; refetch: ({ entityId, params, }: { entityId?: string; params?: GetEntityParams; }) => Promise<void>; lastParams: GetEntityParams | null; }; export { type EntityProvider, useEntityProvider };