Skip to main content
Deno 2 is finally here 🎉️
Learn more
Module

x/ayonli_jsext/http/util.ts>ifNoneMatch

A JavaScript extension package for building strong and modern applications.
Latest
function ifNoneMatch
import { ifNoneMatch } from "https://deno.land/x/ayonli_jsext@v0.9.72/http/util.ts";

Checks if the value from the If-None-Match header matches the given ETag.

Examples

Example 1

import { etag, ifNoneMatch } from "@ayonli/jsext/http";

const _etag = await etag("Hello, World!");
const match = ifNoneMatch("d-3/1gIbsr1bCvZ2KQgJ7DpTGR3YH", _etag);
console.log(match); // false

Parameters

value: string | null
etag: string

Returns

boolean