CrossClj

1.6.1 docs

SourceDocs



RECENT

    compojure

    Clojars

    Apr 14, 2018


    OWNER
    James Reeves
    Boolean Knot Ltd
    London, UK
    jreeves@booleanknot.com
    www.booleanknot.com

    Readme

    Index of all namespaces


    « Project + dependencies

    A concise routing library for Ring

    compojure.coercionsDocsSource
    Functions for coercing route parameters into different types.
    
    compojure.coreDocsSource
    A DSL for building Ring handlers from smaller routes.
    
    Compojure routes are semantically the same as Ring handlers, with the
    exception that routes may return nil to indicate they do not match.
    
    This namespace provides functions and macros for concisely constructing
    routes and combining them together to form more complex functions.
    compojure.handlerDocsSource
    Functions to create Ring handlers from routes.
    
    This namespace has been DEPRECATED in favor of the ring-defaults library.
    compojure.responseDocsSource
    A protocol for generating Ring response maps
    
    compojure.routeDocsSource
    Route functions that define common behavior.
    
    The README below is fetched from the published project artifact. Some relative links may be broken.

    Compojure

    Build Status

    Compojure is a small routing library for Ring that allows web applications to be composed of small, independent parts.

    Installation

    Add the following dependency to your project.clj file:

    [compojure "1.6.1"]
    

    Documentation

    Community

    Usage

    This small Compojure application demonstrates creating a Ring handler from two routes:

    (ns hello-world.core
      (:require [compojure.core :refer :all]
                [compojure.route :as route]))
    
    (defroutes app
      (GET "/" [] "<h1>Hello World</h1>")
      (route/not-found "<h1>Page not found</h1>"))
    

    Also refer to the Getting Started page on the wiki.

    License

    Copyright © 2018 James Reeves

    Distributed under the Eclipse Public License, the same as Clojure.