Skip to main content

useChunkFinishListener

Package​

@rpldy/chunked-uploady

Installation​

npm install @rpldy/chunked-uploady

Details​

type useChunkFinishListener = (cb: (data: ChunkFinishEventData) => void) => void;
note

Event Hook - CHUNK_FINISH

Called when a chunk finishes uploading as part of a chunked upload

Example​

import { useChunkFinishListener } from "@rpldy/chunked-uploady";

const MyComponent = () => {
useChunkFinishListener(({ chunk }) => {
console.log(`Chunk Finished - ${chunk.id} - attempt: ${chunk.attempt}`);
});
};