• Returns the converted hex color from the given hsl color

    Parameters

    • Optionalhsl: string | [h: number, s: number, l: number]

      the hsl color to inspect

    Returns string | undefined

    the converted hex color from the given hsl color

    hslToHex('hsl(360, 1, 0.5)');    // '#ff0000'
    hslToHex([360, 1, 0.5]); // '#ff0000'