Skip to content

Commit

Permalink
Circle #276
Browse files Browse the repository at this point in the history
  • Loading branch information
yogthos committed Jan 31, 2024
1 parent ad37d5e commit e0e5b75
Showing 1 changed file with 3 additions and 4 deletions.
7 changes: 3 additions & 4 deletions docs/docs/integrant.html
Original file line number Diff line number Diff line change
Expand Up @@ -115,10 +115,9 @@ <h2>Contents</h2>
&#40;layout/init-selmer!&#41;
&#91;base-path &#40;route-data opts&#41; &#40;page-routes opts&#41;&#93;&#41;
</code></pre><p>The multimethod attaches the <code>opts</code> to the request map by calling <code>&#40;route-data opts&#41;</code>, and the request handle function can now access the <code>:query-fn</code> key from the request map by calling <code>&#40;utils/route-data request&#41;</code> as follows:</p><pre><code class="clojure">
&#40;defn home &#91;{:keys &#91;flash&#93; :as request}&#93;
&#40;let &#91;{:keys &#91;query-fn&#93;} &#40;utils/route-data request&#41;&#93;
&#40;layout/render request &quot;home.html&quot; {:messages &#40;query-fn :get-messages {}&#41;
:errors &#40;:errors flash&#41;}&#41;&#41;&#41;
&#40;defn home &#91;{:keys &#91;query-fn&#93;} {:keys &#91;flash&#93; :as request}&#93;
&#40;layout/render request &quot;home.html&quot; {:messages &#40;query-fn :get-messages {}&#41;
:errors &#40;:errors flash&#41;}&#41;&#41;
</code></pre>
</div>
</div>
Expand Down

0 comments on commit e0e5b75

Please sign in to comment.