gossamer/response

Types

pub type Response

Values

pub fn array_buffer(
  of response: Response,
) -> promise.Promise(Result(array_buffer.ArrayBuffer, String))
pub fn blob(
  of response: Response,
) -> promise.Promise(Result(blob.Blob, String))
pub fn body(
  of response: Response,
) -> Result(
  readable_stream.ReadableStream(uint8_array.Uint8Array),
  Nil,
)
pub fn bytes(
  of response: Response,
) -> promise.Promise(Result(uint8_array.Uint8Array, String))
pub fn clone(response: Response) -> Response
pub fn error() -> Response
pub fn form_data(
  of response: Response,
) -> promise.Promise(Result(form_data.FormData, String))
pub fn from_json(
  data: a,
  with init: List(response_init.ResponseInit),
) -> Response
pub fn headers(of response: Response) -> headers.Headers
pub fn is_body_used(response: Response) -> Bool
pub fn is_ok(response: Response) -> Bool
pub fn is_redirected(response: Response) -> Bool
pub fn json(
  of response: Response,
) -> promise.Promise(Result(dynamic.Dynamic, String))
pub fn new(body: String) -> Result(Response, String)
pub fn new_with_init(
  body: String,
  with init: List(response_init.ResponseInit),
) -> Result(Response, String)
pub fn redirect(url: String) -> Response
pub fn redirect_with_status(
  url: String,
  status status: Int,
) -> Response
pub fn status(of response: Response) -> Int
pub fn status_text(of response: Response) -> String
pub fn text(
  of response: Response,
) -> promise.Promise(Result(String, String))
pub fn type_(of response: Response) -> response_type.ResponseType
pub fn url(of response: Response) -> String
Search Document