• Parameters

    • string: string

      a CSS/SVG color string in any form

    Returns string

    a hex-color form of the input color string.

    Description

    input a color as a string and return the same color as a hex value string. This supports CSS/SVG color strings like named colors, hex colors, rgb(), hsl().