Skip to main content
Module

x/faster/deps.ts>Cookie

A fast and optimized middleware server with an absurdly small amount of code (300 lines) built on top of Deno's native HTTP APIs with no dependencies. It also has a collection of useful middlewares: log file, serve static, CORS, session, rate limit, token, body parsers, redirect, proxy and handle upload. In "README" there are examples of all the resources. Faster's ideology is: all you need is an optimized middleware manager, all other functionality is middleware.
Go to Latest
interface Cookie
import { type Cookie } from "https://deno.land/x/faster@v5.7/deps.ts";

Properties

name: string

Name of the cookie.

value: string

Value of the cookie.

optional
expires: Date

Expiration date of the cookie.

optional
maxAge: number

Max-Age of the Cookie. Max-Age must be an integer superior or equal to 0.

optional
domain: string

Specifies those hosts to which the cookie will be sent.

optional
path: string

Indicates a URL path that must exist in the request.

optional
secure: boolean

Indicates if the cookie is made using SSL & HTTPS.

optional
httpOnly: boolean

Indicates that cookie is not accessible via JavaScript.

optional
sameSite: "Strict" | "Lax" | "None"

Allows servers to assert that a cookie ought not to be sent along with cross-site requests.

optional
unparsed: string[]

Additional key value pairs with the form "key=value"