Defined in: src/browser/core.ts:42
Core configuration shared by both useUpload and useMultipleUpload.
Each hook extends this with hook-specific options.
Extended by
Properties
allowedTypes?
optionalallowedTypes:string[]
Defined in: src/browser/core.ts:54
Allowed MIME types (e.g. ["image/png", "image/jpeg"]).
Supports wildcard subtypes such as "image/*".
Default
undefined — all types allowedheaders?
optionalheaders:Record<string,string>
Defined in: src/browser/core.ts:81
Extra headers to send with the PUT request.
Content-Type is set automatically from the file’s MIME type
unless you provide an explicit Content-Type key here.
maxFileSize?
optionalmaxFileSize:number
Defined in: src/browser/core.ts:47
Maximum allowed file size in bytes.
Default
Infinityretries?
optionalretries:number
Defined in: src/browser/core.ts:67
Number of automatic retries on transient failures: network errors, timeouts, HTTP 429, and HTTP 5xx.
Default
0retryDelay?
optionalretryDelay:number
Defined in: src/browser/core.ts:74
Base delay in ms for exponential back-off between retries.
Actual delay = retryDelay × 2^attempt (capped at 30 s).
Default
1000signal?
optionalsignal:AbortSignal
Defined in: src/browser/core.ts:88
An AbortSignal for external cancellation (e.g. from an AbortController,
React Query, or TanStack Query). When the signal fires, the in-flight XHR
is aborted immediately. Works alongside the hook’s built-in abort() method.
timeout?
optionaltimeout:number
Defined in: src/browser/core.ts:60
Upload timeout in milliseconds. Set to 0 to disable.
Default
0