useQueue
import { useQueue } from "@hyper-fetch/react"
Description
Defined in react/src/hooks/use-queue/use-queue.hooks.ts:14
Preview
useQueue<Request>(request, options)
Parameters
Returns
{
pause: () => void;
requests: {
request: Request;
requestId: string;
retries: number;
stopped: boolean;
timestamp: number;
deleteRequest: () => void;
downloading: {
loaded: number;
progress: number;
sizeLeft: number;
startTimestamp: number;
timeLeft: number | null;
total: number;
};
startRequest: () => void;
stopRequest: () => void;
uploading: {
loaded: number;
progress: number;
sizeLeft: number;
startTimestamp: number;
timeLeft: number | null;
total: number;
};
}[];
start: () => void;
stop: () => void;
stopped: boolean;
}