/** * Zudux-State React API. * Created and maintained by Pradeep Kumar Sheoran (Stack Developer), * BSG Technologies — https://bsgtechnologies.com */ import { createElement } from 'react'; import type { ReactNode } from 'react'; import type { ArgumentOf, DataOf, ResourceCatalog, ResourceHub, ResourceSnapshot } from './resources.js'; import type { CommandCatalog, Domain, Equality, PayloadOf, ResultOf, RunMeta } from './types.js'; export declare function useDomainSlice, Slice>(domain: Domain, select: (state: Readonly) => Slice, equality?: Equality): Slice; export declare function useDomainRevision>(domain: Domain): number; export declare function useCommand, Name extends keyof Commands & string>(domain: Domain, name: Name, meta?: RunMeta): (payload: PayloadOf) => Promise>; export interface DomainScope> { Provider(props: { readonly domain?: Domain; readonly children?: ReactNode; }): ReturnType; useDomain(): Domain; useSlice(select: (state: Readonly) => Slice, equality?: Equality): Slice; } export declare function createDomainScope>(factory?: () => Domain): DomainScope; export declare function useResource(hub: ResourceHub, name: Name, argument: ArgumentOf, options?: { readonly enabled?: boolean; readonly force?: boolean; }): ResourceSnapshot>; export declare function useResourceSuspense(hub: ResourceHub, name: Name, argument: ArgumentOf): DataOf; //# sourceMappingURL=react.d.ts.map