We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
2 parents 0a192a1 + 14f5df0 commit 757bef9Copy full SHA for 757bef9
doc.go
@@ -47,6 +47,10 @@ variable will be anything until the next slash. For example:
47
r.HandleFunc("/articles/{category}/", ArticlesCategoryHandler)
48
r.HandleFunc("/articles/{category}/{id:[0-9]+}", ArticleHandler)
49
50
+Groups can be used inside patterns, as long as they are non-capturing (?:re). For example:
51
+
52
+ r.HandleFunc("/articles/{category}/{sort:(?:asc|desc|new)}", ArticlesCategoryHandler)
53
54
The names are used to create a map of route variables which can be retrieved
55
calling mux.Vars():
56
0 commit comments