helping cljdoc

This commit is contained in:
Tommi Reiman 2018-05-29 23:18:06 +03:00
parent 7acf3f3357
commit 578cad797e

View file

@ -2,15 +2,15 @@
Routers can be configured via options. The following options are available for the `reitit.core/router`: Routers can be configured via options. The following options are available for the `reitit.core/router`:
| key | description | | key | description |
|--------------|-------------| |--------------|-------------|
| `:path` | Base-path for routes | | `:path` | Base-path for routes |
| `:routes` | Initial resolved routes (default `[]`) | | `:routes` | Initial resolved routes (default `[]`) |
| `:data` | Initial route data (default `{}`) | | `:data` | Initial route data (default `{}`) |
| `:spec` | clojure.spec definition for a route data, see `reitit.spec` on how to use this | | `:spec` | clojure.spec definition for a route data, see `reitit.spec` on how to use this |
| `:expand` | Function of `arg opts => data` to expand route arg to route data (default `reitit.core/expand`) | | `:expand` | Function of `arg opts => data` to expand route arg to route data (default `reitit.core/expand`) |
| `:coerce` | Function of `route opts => route` to coerce resolved route, can throw or return `nil` | | `:coerce` | Function of `route opts => route` to coerce resolved route, can throw or return `nil` |
| `:compile` | Function of `route opts => result` to compile a route handler | | `:compile` | Function of `route opts => result` to compile a route handler |
| `:validate` | Function of `routes opts => ()` to validate route (data) via side-effects | | `:validate` | Function of `routes opts => ()` to validate route (data) via side-effects |
| `:conflicts` | Function of `{route #{route}} => ()` to handle conflicting routes (default `reitit.core/throw-on-conflicts!`) | | `:conflicts` | Function of `{route #{route}} => ()` to handle conflicting routes (default `reitit.core/throw-on-conflicts!`) |
| `:router` | Function of `routes opts => router` to override the actual router implementation | | `:router` | Function of `routes opts => router` to override the actual router implementation |