January 2014
Intermediate to advanced
232 pages
5h 11m
English
In this section we’ll cover how to create a simple application that serves static resources, provides basic session management, and handles JavaScript Object Notation (JSON) operations.
First let’s create a new application called liberator-service using the compojure-app template.
| | lein new compojure-app liberator-service |
Once the application is created, add Liberator and Cheshire dependencies to our project.clj dependencies vector:[40]
| | :dependencies |
| | [ ... |
| | [liberator "0.11.0"] |
| | [cheshire "5.3.1"]] |
Cheshire is a fast and easy-to-use JSON parsing library. We’ll use it for parsing the requests from the client and generating the responses.
At this point, we should be able to start up the read-evaluate-print ...
Read now
Unlock full access