Skip to content
This repository
Fetching contributors…

Cannot retrieve contributors at this time

file 19 lines (18 sloc) 3.164 kb
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19
<!DOCTYPE html>
<html><head><meta charset="UTF-8"><link href="css/default.css" rel="stylesheet" type="text/css"><script src="js/jquery.min.js" type="text/javascript"></script><script src="js/page_effects.js" type="text/javascript"></script><title>compojure.handler documentation</title></head><body><div id="header"><h2>Generated by <a href="https://github.com/weavejester/codox">Codox</a></h2><h1><a href="index.html">Compojure 1.1.8 API documentation</a></h1></div><div class="sidebar" id="namespaces"><h3><a href="index.html"><span class="inner">Namespaces</span></a></h3><ul><li class="depth-1"><div class="no-link"><div class="inner"><span class="tree"><span class="top"></span><span class="bottom"></span></span><span>compojure</span></div></div></li><li class="depth-2 branch"><a href="compojure.core.html"><div class="inner"><span class="tree"><span class="top"></span><span class="bottom"></span></span><span>core</span></div></a></li><li class="depth-2 branch current"><a href="compojure.handler.html"><div class="inner"><span class="tree"><span class="top"></span><span class="bottom"></span></span><span>handler</span></div></a></li><li class="depth-2 branch"><a href="compojure.response.html"><div class="inner"><span class="tree"><span class="top"></span><span class="bottom"></span></span><span>response</span></div></a></li><li class="depth-2"><a href="compojure.route.html"><div class="inner"><span class="tree"><span class="top"></span><span class="bottom"></span></span><span>route</span></div></a></li></ul></div><div class="sidebar" id="vars"><h3><a href="#top"><span class="inner">Public Vars</span></a></h3><ul><li class="depth-1"><a href="compojure.handler.html#var-api"><div class="inner"><span>api</span></div></a></li><li class="depth-1"><a href="compojure.handler.html#var-site"><div class="inner"><span>site</span></div></a></li></ul></div><div class="namespace-docs" id="content"><h2 class="anchor" id="top">compojure.handler</h2><pre class="doc">Functions to create Ring handlers from routes.
</pre><div class="public anchor" id="var-api"><h3>api</h3><div class="usage"><code>(api routes)</code></div><pre class="doc">Create a handler suitable for a web API. This adds the following
middleware to your routes:
  - wrap-params
  - wrap-nested-params
  - wrap-keyword-params</pre><div class="src-link"><a href="http://github.com/weavejester/compojure/blob/1.1.8/src/compojure/handler.clj#L16">view source</a></div></div><div class="public anchor" id="var-site"><h3>site</h3><div class="usage"><code>(site routes &amp; [opts])</code></div><pre class="doc">Create a handler suitable for a standard website. This adds the
following middleware to your routes:
  - wrap-session
  - wrap-flash
  - wrap-cookies
  - wrap-multipart-params
  - wrap-params
  - wrap-nested-params
  - wrap-keyword-params

A map of options may also be provided. These keys are provided:
  :session - a map of session middleware options
  :multipart - a map of multipart-params middleware options</pre><div class="src-link"><a href="http://github.com/weavejester/compojure/blob/1.1.8/src/compojure/handler.clj#L28">view source</a></div></div></div></body></html>
Something went wrong with that request. Please try again.