react
The provider and the hooks.
@softzweig/suitcase-react is a headless binding over the client. It renders nothing.
Provider
Section titled “Provider”import { SuitcaseProvider } from "@softzweig/suitcase-react";
<SuitcaseProvider client={client}> <App /></SuitcaseProvider>;The provider holds the client and creates the upload queue that every upload under it shares. Build the client once, outside React.
useSuitcaseClient<T>();useUploadQueue<T>();useUploadResource<T>();useResolveResource(client, kind?, input);useResolveResources(client, kind?, input);useUpdateResource<T>();useDeleteResource<T>();See React hooks for phases, inputs, and batching.
What it does not do
Section titled “What it does not do”- It does not style or render components.
- It does not cache resources between resolves.
- It does not decide what to render after a mutation. Drop the row from your state, or refresh the query that produced it.
Peer requirement
Section titled “Peer requirement”React 19 or newer.