mirror of
https://github.com/metosin/reitit.git
synced 2025-12-17 00:11:11 +00:00
The previous example only worked by accident (because there was an even number of map keys with conditional values).
{:get #?(:clj 1), :post #?(:clj 2)} gets read as {:get :post} in a non-clj context. The splicing reader conditional or a :cljs (or :default) value is needed to have the code work as intended. Here we change the docs to use the splicing version, as that is (imho) more beautiful than adding another branch.
|
||
|---|---|---|
| .. | ||
| composing_routers.md | ||
| configuring_routers.md | ||
| dev_workflow.md | ||
| different_routers.md | ||
| route_validation.md | ||
| shared_routes.md | ||