File tree Expand file tree Collapse file tree 3 files changed +27
-3
lines changed
Expand file tree Collapse file tree 3 files changed +27
-3
lines changed Original file line number Diff line number Diff line change 1- === master
1+ === 3.96.0 (2025-09-12)
22
3- * Add redirect_path plugin, for automatically using the calling path with the redirect argument if not given a string (jeremyevans)
3+ * Add redirect_path plugin, for automatically calling path with the redirect argument if not given a string (jeremyevans)
44
55=== 3.95.0 (2025-08-12)
66
Original file line number Diff line number Diff line change 1+ = New Features
2+
3+ * A redirect_path plugin has been added, which integrates the path
4+ plugin with r.redirect:
5+
6+ Foo = Struct.new(:id)
7+ foo = Foo.new(1)
8+
9+ plugin :path
10+ path Foo do |foo|
11+ "/foo/#{foo.id}"
12+ end
13+
14+ route do |r|
15+ r.get "example" do
16+ # redirects to /foo/1
17+ r.redirect(foo)
18+ end
19+
20+ r.get "suffix-example" do
21+ # redirects to /foo/1/status
22+ r.redirect(foo, "/status")
23+ end
24+ end
Original file line number Diff line number Diff line change @@ -4,7 +4,7 @@ class Roda
44 RodaMajorVersion = 3
55
66 # The minor version of Roda, updated for new feature releases of Roda.
7- RodaMinorVersion = 95
7+ RodaMinorVersion = 96
88
99 # The patch version of Roda, updated only for bug fixes from the last
1010 # feature release.
You can’t perform that action at this time.
0 commit comments