(func r)(has-options? r)(new-route p-route interceptor)(options r)Returns the route-name or constraints options in a map when present
Returns the route-name or constraints options in a map when present
(route-length route-definition)Returns the complexity of the route: :first
Returns the complexity of the route:
:first
- minimum route
- ["/users" :get view-users]
:second
- Has either a route name or constraints
- Route Name: ["/user" :get view-user :route-name :view-user-profile]
- Constraints: ["/user/:user-id" :get view-user :constraints {:user-id #"[0-9]+"}]
:third
- Hash both a route name and constraints
- ["/user/:user-id" :get view-user :route-name :view-user-profile :constraints {:user-id #"[0-9]+"}]cljdoc builds & hosts documentation for Clojure/Script libraries
| Ctrl+k | Jump to recent docs |
| ← | Move to previous article |
| → | Move to next article |
| Ctrl+/ | Jump to the search field |