FetchOptions

sealed abstract class FetchOptions extends Product with Serializable

Options to pass to Fetch when using a FetchClient

Value Params
cache

how the request will interact with the browser’s HTTP cache

credentials

what browsers do with credentials (cookies, HTTP authentication entries, and TLS client certificates)

integrity

subresource integrity value of the request

keepAlive

used to allow the request to outlive the page

mode

mode you want to use for the request, e.g., cors, no-cors, or same-origin

redirect

how to handle a redirect response

referrer

referrer of the request, this can be a same-origin URL, about:client, or an empty string.

referrerPolicy

referrer policy to use for the request

requestTimeout

maximum duration from the submission of a request through reading the body before a timeout.

Companion
object
trait Serializable
trait Product
trait Equals
class Object
trait Matchable
class Any

Value members

Abstract methods

def cache: Option[RequestCache]
def credentials: Option[RequestCredentials]
def integrity: Option[String]
def keepAlive: Option[Boolean]
def mode: Option[RequestMode]
def redirect: Option[RequestRedirect]
def referrer: Option[FetchReferrer]
def referrerPolicy: Option[ReferrerPolicy]
def withCacheOption(cache: Option[RequestCache]): FetchOptions
def withCredentialsOption(credentials: Option[RequestCredentials]): FetchOptions
def withIntegrityOption(integrity: Option[String]): FetchOptions
def withKeepAliveOption(keepAlive: Option[Boolean]): FetchOptions
def withModeOption(mode: Option[RequestMode]): FetchOptions
def withRedirectOption(redirect: Option[RequestRedirect]): FetchOptions
def withReferrerPolicyOption(referrerPolicy: Option[ReferrerPolicy]): FetchOptions

Concrete methods

final def merge(other: FetchOptions): FetchOptions

Merge Two FetchOptions. other is prioritized.

Merge Two FetchOptions. other is prioritized.

final def withCache(cache: RequestCache): FetchOptions
final def withCredentials(credentials: RequestCredentials): FetchOptions
final def withIntegrity(integrity: String): FetchOptions
final def withKeepAlive(keepAlive: Boolean): FetchOptions
final def withMode(mode: RequestMode): FetchOptions
final def withRedirect(redirect: RequestRedirect): FetchOptions
final def withReferrerPolicy(referrerPolicy: ReferrerPolicy): FetchOptions

Inherited methods

def canEqual(that: Any): Boolean
Inherited from
Equals
def productArity: Int
Inherited from
Product
def productElement(n: Int): Any
Inherited from
Product
def productElementName(n: Int): String
Inherited from
Product
def productElementNames: Iterator[String]
Inherited from
Product
def productIterator: Iterator[Any]
Inherited from
Product
def productPrefix: String
Inherited from
Product