Skip to main content
Go to Latest
function preferredEncodings
import { preferredEncodings } from "https://deno.land/std@0.152.0/http/_negotiation/encoding.ts";

Given an Accept-Encoding string, parse out the encoding returning a negotiated encoding based on the provided encodings otherwise just a prioritized array of encodings.

Parameters

accept: string
optional
provided: string[]

Returns

string[]