Function tryParseContentType

  • Attempts to parse the content-type of a HTTP response in a MediaType. If parse was not sucessful, defaults to binary.

    Parameters

    • type: null | string

      the parsing header Content-Type value.

    Returns MediaType

    the MediaType value that matches the input type.

Generated using TypeDoc