A smarter client-side in ClojureScript
Shoreleave is a collection of integrated libraries that focuses on:
- Idiomatic interfaces
- Common client-side strategies
- HTML5 capabilities
- ClojureScript's advantages
Shoreleave-baseline is a starting point for building applications with Ring+Compojure+lib-noir+Shoreleave. It fills the same role as ClojureScript:One - it is an example/foundation from which you can build up.
There are four branches within the repo:
cleaninvolves almost no code. It's a minimal, running template app that you can fill in and customize.
masterinvolves trivial code that illustrates proper usage of the most common Shoreleave modules.
kitchensinkinvolves ALL Shoreleave modules working in concert. This is great to smoketest Shoreleave.
incubatorinvolves all new features being tested or developed for Shoreleave. DO NOT USE THIS BRANCH
Shoreleave-baseline is already wired up to do a host of best-practices for web applications. This includes, but is not limited to client-side caching, compression, and CSRF protection (all via Ring Middleware).
A sane file structure has been imposed on the example, as well as smart default options.
A central config file for the app can be found at
resources/config.edn and is accessed through the
The config system can easily be replaced with environ or carica.
Launching the server
The server can be launched in a few ways.
- From the REPL with:
(defonce server (start-server))
- Launching a quick dev server with:
- Launching a dev server with Lein Ring:
lein ring server
- Launching a prod server with Lein Ring:
lein with-profile production ring server-headless
File structure and outline
Plays well with others
Shoreleave makes no assumptions about other libraries you might be using in your application.
You should extend the example in anyway that makes sense.
Copyright © 2013 Paul deGrandis
Distributed under the Eclipse Public License, the same as Clojure.
Please see the
LICENSE_epl.html for details.