Documentation
¶
Index ¶
- func CheckPasswordHash(hash, password string) bool
- func GetEnvBool(e string) bool
- func GetEnvInt(e string) int
- func GetEnvString(e string) string
- func HashPassword(password string) (string, error)
- func IsValid(s string) bool
- func NewResponses[T any](ctx *gin.Context, statusCode int, message string, data T, err error, ...)
- func OptionsHandler(ctx *gin.Context)
- func RandomStringBytesMaskImprSrcSB(n int) string
- type BaseResponse
- type Meta
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func CheckPasswordHash ¶
CheckPasswordHash will compare current password with hashed password in database
func GetEnvBool ¶
func GetEnvString ¶
func HashPassword ¶
HashPassword will transform from plain password into hashed password
func NewResponses ¶
func NewResponses[T any](ctx *gin.Context, statusCode int, message string, data T, err error, meta *Meta)
NewResponses return dynamic JSON responses
func OptionsHandler ¶
OptionsHandler will handing preflight requests
func RandomStringBytesMaskImprSrcSB ¶
RandomStringBytesMaskImprSrcSB will generating a unique random alphanumeric with fixed length
Types ¶
type BaseResponse ¶
Click to show internal directories.
Click to hide internal directories.