validate

package
v0.0.2 Latest Latest
Warning

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

Go to latest
Published: Oct 12, 2022 License: MIT Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	RepoName = regexp.MustCompile(`^[a-zA-Z0-9_\-/]+$`).MatchString
	Name     = regexp.MustCompile(`^[a-zA-Z0-9_\-]+$`).MatchString

	Email = commonregex.EmailRegex.MatchString
)

Functions

func Duration

func Duration(field, value string) (time.Duration, error)

func Field

func Field(field, value string, f func(string) bool) error

func In

func In(field, value string, in []string) error

func Require

func Require(field, value string) error

Types

This section is empty.

Jump to

Keyboard shortcuts

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