RequestOptionsBase interface

描述將用於每個作業之 options 物件的基底結構。

屬性

abortSignal

可用來中止要求的訊號。

customHeaders

使用者定義自訂要求標頭,將在傳送要求之前套用。

onDownloadProgress

下載進度時引發的回呼。

onUploadProgress

上傳進度時引發的回呼。

timeout

要求在自動終止之前可能需要的毫秒數。

屬性詳細資料

abortSignal

可用來中止要求的訊號。

abortSignal?: AbortSignalLike

屬性值

customHeaders

使用者定義自訂要求標頭,將在傳送要求之前套用。

customHeaders?: {[key: string]: string}

屬性值

{[key: string]: string}

onDownloadProgress

下載進度時引發的回呼。

onDownloadProgress?: (progress: TransferProgressEvent) => void

屬性值

(progress: TransferProgressEvent) => void

onUploadProgress

上傳進度時引發的回呼。

onUploadProgress?: (progress: TransferProgressEvent) => void

屬性值

(progress: TransferProgressEvent) => void

timeout

要求在自動終止之前可能需要的毫秒數。

timeout?: number

屬性值

number