mirror of
https://github.com/kataras/iris.git
synced 2026-01-07 20:17:05 +00:00
Helpers for third-party adaptors and middleware authors to generate route paths without even know the router that has being selected by user
Former-commit-id: b21147f2bc306d5c41539a1be0c83456c3d62651
This commit is contained in:
@@ -545,6 +545,9 @@ func New() iris.Policies {
|
||||
// finally return the path given + the wildcard path part
|
||||
return path + wildcardPart
|
||||
},
|
||||
Param: func(paramName string) string {
|
||||
return string(parameterStartByte) + paramName
|
||||
},
|
||||
// path = "/api/users/:id", args = ["42"]
|
||||
// return "/api/users/42"
|
||||
//
|
||||
|
||||
Reference in New Issue
Block a user