package http-cookie
HTTP cookie library for OCaml
Install
Dune Dependency
Authors
Maintainers
Sources
http-cookie-v4.0.0.tbz
sha256=4c02689804446e1240de8eb3fe9344ca256aab5aa7143516c086553006b6c6d6
sha512=0a9f26e2ed68c9d3596212ad091d98cefb0c41292dc1dd7e27cb6e3da5994e420f3ccbf528ee07c4cc42d220d942c9ffaa70dd9d213ec8cf94241315b2d821bc
README.md.html
Cookies
A comprehensive and standards compliant HTTP cookies library for ocaml.
HTTP cookies are serialized as follows:
In a
Cookie
header in a HTTP requestIn a
Set-Cookie
header in a HTTP response.
The library supports consuming and creating HTTP cookies in both requests and responses.
The standards implemented by the library is
Installation
$ opam install http-cookie
Usage
Create a cookie,
Http_cookie.create "SID" "23432324"
Serialize cookie to a HTTP Set-Cookie
header value,
let s = Http_cookie.to_set_cookie_header_value c in
s = "SID=31d4d96e407aad42; Path=/; Secure; HttpOnly; Expires=Sun, 06 Nov 1994 08:49:37 GMT"
sectionYPositions = computeSectionYPositions($el), 10)"
x-init="setTimeout(() => sectionYPositions = computeSectionYPositions($el), 10)"
>