Home / Function/ Render() — gin Function Reference

Render() — gin Function Reference

Architecture documentation for the Render() function in redirect.go from the gin codebase.

Entity Profile

Relationship Graph

Source Code

render/redirect.go lines 20–26

func (r Redirect) Render(w http.ResponseWriter) error {
	if (r.Code < http.StatusMultipleChoices || r.Code > http.StatusPermanentRedirect) && r.Code != http.StatusCreated {
		panic(fmt.Sprintf("Cannot redirect with status code %d", r.Code))
	}
	http.Redirect(w, r.Request, r.Location, r.Code)
	return nil
}

Subdomains

Analyze Your Own Codebase

Get architecture documentation, dependency graphs, and domain analysis for your codebase in minutes.

Try Supermodel Free