-
-
Notifications
You must be signed in to change notification settings - Fork 1.1k
Open
Description
Commented here, but since the issue cannot be reopened, I opened this issue to continue the discussion.
Copy of my comment there:
I'm not sure whether my question relates to the initial question, but perhaps it makes sense when subrouters are used? Consider this:
router.Route("/{username}", func(r chi.Router) { r.Get("/", func(w http.ResponseWriter, request *http.Request) { // r.Redirect("/details") <---- This is where I want to redirect to, keeping the subrouter's prefix (/{username}). }) r.Get("/details", func(writer http.ResponseWriter, request *http.Request) { // ... <---- Redirects here }) }
Originally posted by @shamilovstas in #709
AnatinttiL
Metadata
Metadata
Assignees
Labels
No labels