util

package
v0.0.0-...-99638a4 Latest Latest
Warning

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

Go to latest
Published: Nov 12, 2022 License: MIT Imports: 11 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func GetImage

func GetImage(id string, isShiny bool) typdef.PokeImg

func GetPokemon

func GetPokemon(id string, out chan<- typdef.PokeResult)

func ImageToASCII

func ImageToASCII(img image.Image, width, height int, fit bool) string

func Max

func Max(a, b int) int

func Min

func Min(a, b int) int

func Reverse

func Reverse[T any](a []T) []T

func Substring

func Substring(str string, start, length int) string

Substring returns a substring of str starting at a 0-based index and ending after a certain amount of characters. Negative numbers do not work.

func Title

func Title(str string) string

func URLToImage

func URLToImage(url string) (image.Image, error)

Types

This section is empty.

Jump to

Keyboard shortcuts

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