modulepackage
0.0.0-20240604005652-7682738f466f
Repository: https://github.com/scott-x/mdw.git
Documentation: pkg.go.dev
# README
mdw
gin middleware
note
Before using the middleware, please remember to init headerName
secret
& expire
.
Here is the example:
mdw.SetSecret("balabala..")
mdw.SetHeaderName("xxx")
mdw.SetJWTExpire(20) //20 seconds
Full example can be seen here
# Functions
No description provided by the author
AuthRequired jwt.
create jwt token with user id.
get user id.
No description provided by the author
jwt expire time.
secret.