mirror of
https://github.com/metosin/reitit.git
synced 2025-12-17 08:21:11 +00:00
Merge pull request #252 from aarongroom/fix/misc-documentation-edits
Fix some documentation wording
This commit is contained in:
commit
51462e345e
3 changed files with 3 additions and 3 deletions
|
|
@ -1,6 +1,6 @@
|
|||
# Name-based (reverse) Routing
|
||||
|
||||
All routes which have `:name` route data defined, can also be matched by name.
|
||||
All routes which have `:name` route data defined can also be matched by name.
|
||||
|
||||
Given a router:
|
||||
|
||||
|
|
|
|||
|
|
@ -1,6 +1,6 @@
|
|||
# Route Conflicts
|
||||
|
||||
We should fast if a router contains conflicting paths or route names.
|
||||
We should fail fast if a router contains conflicting paths or route names.
|
||||
|
||||
When a `Router` is created via `reitit.core/router`, both path and route name conflicts are checked automatically. By default, in case of conflict, an `ex-info` is thrown with a descriptive message. In some (legacy api) cases, path conflicts should be allowed and one can override the path conflict resolution via `:conflicts` router option.
|
||||
|
||||
|
|
|
|||
|
|
@ -1,6 +1,6 @@
|
|||
# Route Data Validation
|
||||
|
||||
Route data can be anything, so it's easy to do go wrong. Accidentally adding a `:role` key instead of `:roles` might hinder the whole routing app without any authorization in place.
|
||||
Route data can be anything, so it's easy to go wrong. Accidentally adding a `:role` key instead of `:roles` might hinder the whole routing app without any authorization in place.
|
||||
|
||||
To fail fast, we could use the custom `:coerce` and `:compile` hooks to apply data validation and throw exceptions on first sighted problem.
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue