util

package
v1.0.11 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jul 12, 2025 License: Apache-2.0 Imports: 21 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Diff

func Diff(a, b any) string

func FormatInt added in v1.0.7

func FormatInt(i int) string

func GetToday added in v1.0.7

func GetToday(n ...int) time.Time

func HMAC256 added in v1.0.4

func HMAC256(key, content string) string

func HMAC256Hex

func HMAC256Hex(key, content string) string

func Hash added in v1.0.4

func Hash(h hash.Hash, content string) string

func HashHex

func HashHex(h hash.Hash, content string) string

func MD5Hex

func MD5Hex(content string) string

func NodeAttrExists

func NodeAttrExists(node *html.Node, fn func(attr html.Attribute) bool) bool

func NodeAttrSearch

func NodeAttrSearch(node *html.Node, fn func(attr html.Attribute) bool) string

func NodeChildren

func NodeChildren(node *html.Node, childTags ...string) (nodes []*html.Node)

func NodeSearch

func NodeSearch(node *html.Node, fn func(node *html.Node) bool) *html.Node

func NodeTitle

func NodeTitle(node *html.Node) string

func Ntfy

func Ntfy(topic, title, text string)

func RandAlphanum

func RandAlphanum(n int) string

func RandDict

func RandDict(dict string, n int) string

func RandHex

func RandHex(n int) string

func SHA256Hex

func SHA256Hex(content string) string

func ToMap

func ToMap[T any](input any) map[string]T

func ToMapString added in v1.0.6

func ToMapString(input any) map[string]string

func UUID

func UUID() string

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL