• Escapes a string to be included into comment withing HTTP header value.

    Replaces \ with \, " with \", ( with \(, and ) with \).

    According to RFC7230 the sender should not escape a double quote in this case. However, it may be necessary to distinguish between raw double quote and nested quoted-string.

    Parameters

    • string: string

      A string to escape.

    Returns string

    Escaped string.

Generated using TypeDoc