You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardexpand all lines: doc/basics/route_data.md
+2
Original file line number
Diff line number
Diff line change
@@ -85,6 +85,8 @@ Resolved route tree:
85
85
; :roles #{:db-admin}}]]
86
86
```
87
87
88
+
See also [nested parameter definitions for coercions](../ring/coercion.md#nested-parameter-definitions)
89
+
88
90
## Route Data Fragments
89
91
90
92
Just like [fragments in React.js](https://reactjs.org/docs/fragments.html), we can create routing tree fragments by using empty path `""`. This allows us to add route data without accumulating to path.
Defining a coercion for a route data doesn't do anything, as it's just data. We have to attach some code to apply the actual coercion. We can use the middleware from `reitit.ring.coercion`:
0 commit comments