Skip to main content
Module

x/oak/isMediaType.ts>isMediaType

A middleware framework for handling HTTP with Deno 🐿️ 🦕
Extremely Popular
Go to Latest
function isMediaType
import { isMediaType } from "https://deno.land/x/oak@v10.6.0/isMediaType.ts";

Given a value of the content type of a request and an array of types, provide the matching type or false if no types are matched.

Parameters

value: string
types: string[]

Returns

string | false