Color2Hex

Convert color to hex。

Parameters

ParameterTypeDescription

url

string

图像资源

Return Values

string

Examples

package main

import (
    "fmt"
    "github.com/fishtailstudio/imgo"
    "image/color"
)

func main() {
    fmt.Println(imgo.Color2Hex(color.White))
}

Output:

#FFFFFF

Last updated