new CFetchResponse(status, statusText, data)
Constructor for the object.
Parameters:
Name | Type | Description |
---|---|---|
status |
number | The HTTP status of the fetch. |
statusText |
string | The associated text. |
data |
any | The data retrieved. |
- Source:
Members
(readonly, nullable) asBlob :Blob
Will treat the data as a Blob object.
Type:
- Blob
- Source:
(readonly, nullable) asFormData :FormData
Will treat the data as a Blob object.
Type:
- FormData
- Source:
(readonly, nullable) asObject :object
Will treat the data as a JavaScript object.
Type:
- object
- Source:
(readonly, nullable) asString :string
Will treat the data as a string.
Type:
- string
- Source:
(readonly) data :any
The retrieved with the fetch request. May be null.
Type:
- any
- Source:
(readonly) status :number
The HTTP status code of the request.
Type:
- number
- Source:
(readonly) statusText :string
The HTTP status text of the request.
Type:
- string
- Source: