Repository navigation
v0.2.0
What's New
Browser Navigation Methods
Added SSE-based navigation methods to Context:
Redirect(url)/Redirectf(format, args...)- Navigate to a new page (full page load)ReplaceURL(url)/ReplaceURLf(format, args...)- Update browser URL without navigation (history.replaceState)
Example Usage
// Redirect after login
login := c.Action(func() {
if authenticated {
c.Redirect("/dashboard")
}
})
// Update URL for pagination without reload
c.ReplaceURLf("/products?page=%d", page)Updated Examples
- Session example now demonstrates a full login flow with redirects across
/loginand/dashboardpages