All Projects → borkdude → lein2boot

borkdude / lein2boot

Licence: other
The goal of this exercise is to convert a leiningen project to boot and have exactly the same workflow.

Programming Languages

clojure
4091 projects
HTML
75241 projects
CSS
56736 projects

lein2boot

This is a sample project that demonstrates how to achieve the same development and build process in leiningen and boot. There is a blog post about it here.

Both project configurations support:

  • code reloading on the server (Clojure) and on the client (ClojureScript)
  • building production ClojureScript
  • packaging the application as a standalone jar

Leiningen

Developing

In a terminal, start the web server:

lein repl
(start-server)

In another terminal, start figwheel:

lein clean && lein figwheel dev

Browse to http://localhost:8080/index.html.

Building production ClojureScript

lein clean && lein cljsbuild once prod

Package as uberjar

lein clean
lein cljsbuild once prod
lein uberjar

or just

lein build

Run with java -jar target/animals-1.0.0-standalone.jar [<port>]

Boot

Developing

In a terminal:

boot dev

Browse to http://localhost:3000/index.html.

Building production ClojureScript

boot build-cljs

Package as uberjar

boot build

Run with java -jar target/animals-1.0.0.jar [<port>]

Credits

Thanks to

License

Copyright Michiel Borkent

Distributed under the Eclipse Public License either version 1.0 or (at your option) any later version.

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].