@[reducible, inline]
A parsed cookie key-value pair.
Equations
Instances For
Parse a Cookie header value into key-value pairs. Cookie header format: "name1=value1; name2=value2" $$\text{parseCookies} : \text{String} \to \text{List CookiePair}$$
Equations
- One or more equations did not get rendered due to their size.
Instances For
Render a list of cookie pairs into a Cookie header value. $$\text{renderCookies} : \text{List CookiePair} \to \text{String}$$
Equations
- Web.Cookie.renderCookies cookies = "; ".intercalate (List.map (fun (x : Web.Cookie.CookiePair) => match x with | (k, v) => k ++ "=" ++ v) cookies)
Instances For
@[implicit_reducible]
Equations
Equations
- Web.Cookie.instBEqSameSite.beq x✝ y✝ = (x✝.ctorIdx == y✝.ctorIdx)
Instances For
Equations
- Web.Cookie.instReprSameSite.repr Web.Cookie.SameSite.strict prec✝ = Repr.addAppParen (Std.Format.nest (if prec✝ ≥ 1024 then 1 else 2) (Std.Format.text "Web.Cookie.SameSite.strict")).group prec✝
- Web.Cookie.instReprSameSite.repr Web.Cookie.SameSite.lax prec✝ = Repr.addAppParen (Std.Format.nest (if prec✝ ≥ 1024 then 1 else 2) (Std.Format.text "Web.Cookie.SameSite.lax")).group prec✝
- Web.Cookie.instReprSameSite.repr Web.Cookie.SameSite.none_ prec✝ = Repr.addAppParen (Std.Format.nest (if prec✝ ≥ 1024 then 1 else 2) (Std.Format.text "Web.Cookie.SameSite.none_")).group prec✝
Instances For
@[implicit_reducible]
Equations
- Web.Cookie.instReprSameSite = { reprPrec := Web.Cookie.instReprSameSite.repr }
Render a SetCookie as a Set-Cookie header value. $$\text{renderSetCookie} : \text{SetCookie} \to \text{String}$$
Equations
- One or more equations did not get rendered due to their size.
Instances For
Parse a Set-Cookie header value into a SetCookie structure. Only parses the name=value part; attributes are parsed best-effort. $$\text{parseSetCookie} : \text{String} \to \text{Option SetCookie}$$
Equations
- One or more equations did not get rendered due to their size.