CrossClj

0.1.2 docs

SourceDocs



RECENT
    VARS
    *max-compile-depth*
    ->Endpoint
    ->Middleware
    chain
    compile-handler
    compile-result
    ensure-handler!
    expand-and-transform
    IntoMiddleware
    map->Endpoint
    map->Middleware
    middleware-handler
    router

    « Index of all namespaces of this project

    (->Endpoint data handler middleware)
    Positional factory function for class reitit.middleware.Endpoint.
    
    (->Middleware name wrap spec)
    Positional factory function for class reitit.middleware.Middleware.
    
    (chain middleware handler)(chain middleware handler data)(chain middleware handler data opts)
    Creates a Ring middleware chain out of sequence of IntoMiddleware
    and Handler. Optional takes route data and (Router) opts.
    Private
    (compile-handler middleware handler)
    (compile-result route opts)(compile-result [path {:keys [middleware handler], :as data}] opts scope)
    Private
    (ensure-handler! path data scope)
    Private
    (expand-and-transform middleware data {:keys [:reitit.middleware/transform], :or {transform identity}, :as opts})
    protocol
    (into-middleware this data opts)
    (map->Endpoint m__7585__auto__)
    Factory function for class reitit.middleware.Endpoint, taking a map of keywords to field values.
    
    (map->Middleware m__7585__auto__)
    Factory function for class reitit.middleware.Middleware, taking a map of keywords to field values.
    
    (middleware-handler router)
    (router data)(router data opts)
    Creates a [[reitit.core/Router]] from raw route data and optionally an options map with
    support for Middleware. See [docs](https://metosin.github.io/reitit/) for details.
    
    Example:
    
      (router
        ["/api" {:middleware [wrap-format wrap-oauth2]}
          ["/users" {:middleware [wrap-delete]
                       :handler get-user}]])
    
    Options:
    
    | key                            | description |
    | -------------------------------|-------------|
    | :reitit.middleware/transform | Function of `[Middleware] => [Middleware]` to transform the expanded Middleware (default: identity).
    
    See other router options from [[reitit.core/router]].