ConstOptionaloptions: {OptionalgetUploadTotal?: (url: string, opts: WretchOptions) => number | Promise<number>Function used to determine the total upload size before streaming the request body.
Receives the final request URL and options, returns the total byte size (sync or async). Defaults to trying the byteLength property
for ArrayBuffer and the .size property for Blob (e.g., FormData or File), then falling back to Request#blob() when available.
Note: The fallback of using Request#blob() is memory consuming as it loads the entire body into memory.
Adds the ability to monitor progress when downloading a response.
Compatible with all platforms implementing the TransformStream WebAPI.