Developed for the :clojureD conference 2015, "Web Applications by Example", Steffen Beyer. Slides for the talk are here.
Use this project as an example or as template for your own developments.
frontend is the visitor-facing website, backend is the administration panel.
(in terms of libraries and building blocks)
- Light Table – Live-coding environment
- Chestnut – Application template for ClojureScript/Om with live reloading
- Figwheel – Leiningen plugin that pushes ClojureScript code changes to the client
- http-kit – HTTP client/server for Clojure
- PostgreSQL – RDBMS
- Flyway – Database migrations
- Yesql – Simple SQL adapter
- Sente – Bidirectional messaging via WebSockets/AJAX
- Om – ClojureScript interface to Facebook's React
- Bootstrap – HTML, CSS, and JS framework
Create a PostgreSQL database and put the config into project.clj
and src/clj/clojexcms/database.clj
(see #1).
Seed the database by running
lein flyway migrate
Add the folder to your workspace and open src/clj/clojexcms/server.clj
. Evaluate the file, then evaluate the (run)
expression at the bottom.
The call to (run)
does two things, it starts the webserver at port 10555, and also the Figwheel server which takes care of live reloading ClojureScript code and CSS.
View the server starting up in the console.
When you see the line Successfully compiled "resources/public/js/backend/app.js" in 21.36 seconds.
, you're ready to go. Browse to http://localhost:10555
and enjoy.
To shut down the server, open the connections panel and disconnect from clojexcms.
If you want to connect an external browser to Light Table, you need to find out the current port, which changes with each start of Light Table. Open the connections panel, select Browser (External) and insert the displayed port number into env/dev/clj/clojexcms/dev.clj
. Reevaluate the function or restart the server.
Open a terminal and type lein repl
to start a Clojure REPL (interactive prompt).
In the REPL, type
(run)
- Bret Victor
- Anna Pawlicka: Om nom nom nom (Clojure/conj 2014 talk)
- Brandon Bloom: Local State, Global Concerns
- Stuart Sierra: My Clojure Workflow, Reloaded
- Luminus – A Clojure web framework
- Flux application architecture
- CircleCI frontend
- Anton Astashov: Perfect ClojureScript Development Environment With Vim
- Cursive – A Clojure IDE that understands your code
- Dark Admin, MIT license
- Full Width Pics, Apache 2.0 license
Distributed under the Eclipse Public License version 1.0.