Module

x/oak/etag.ts>calculate

A middleware framework for handling HTTP with Deno 🐿️ 🦕
Very Popular
Go to Latest
function calculate
import { calculate } from "https://dotland.deno.dev/x/oak@v12.0.1/etag.ts";

Calculate an ETag value for an entity. If the entity is FileInfo, then the tag will default to a weak ETag. options.weak overrides any default behavior in generating the tag.

Parameters

entity: string | Uint8Array | FileInfo

A string, Uint8Array, or file info to use to generate the ETag

optional
options: ETagOptions = [UNSUPPORTED]

Returns

Promise<string>