• Parses HTTP header values containing directives.

    Directives are parameterized items using spaces instead of semicolons to delimit parameters. While semicolons and colons are used to delimit items.

    Date/time values within directives are usually enclosed into quotes. So, no need to parse them in a special way.

    This is particularly useful when parsing headers such as:

    • Content-Security-Policy
    • Content-Security-Policy-Report-Only
    • Feature-Policy
    • Via
    • Warning

    Parameters

    • this: void
    • value: string

      HTTP header value to parse.

    Returns HthvItem<"has-name" | "no-name", "has-tag" | "no-tag", "has-params" | "no-params">[]

    An array of comma-separated value items with space-separated parameters.

Generated using TypeDoc