CIDER
CIDER is the Clojure(Script) Interactive Development Environment that Rocks!
CIDER extends Emacs with support for interactive programming in Clojure. The
features are centered around cider-mode, an Emacs minor-mode that complements
clojure-mode. While clojure-mode
supports editing Clojure source files,
cider-mode
adds support for interacting with a running Clojure process for
compilation, debugging, definition and documentation lookup, running tests and
so on.
Please consider supporting financially its ongoing development.
Overview
CIDER aims to provide an interactive development experience similar to the one you’d get when programming in Emacs Lisp, Common Lisp (with SLIME or Sly), Scheme (with Geiser) and Smalltalk.
Programmers are expected to program in a very dynamic and incremental manner, constantly re-evaluating existing Clojure definitions and adding new ones to their running applications. You never stop/start a Clojure application while using CIDER - you’re constantly interacting with it and changing it. Depending on who you’re asking that approach is named either "interactive programming/development" or "REPL-driven programming". We prefer the former term and we’ll be using it throughout CIDER’s documentation.
You can find more details about the typical CIDER workflow in the Interactive Programming section. |
CIDER’s built on top of nREPL, the Clojure networked REPL server.
CIDER’s basic architecture looks something like this:
Clojure code gets executed by an nREPL server. CIDER sends requests to the server and processes its responses. The server’s functionality is augmented by additional nREPL middleware, designed specifically to address the needs of an interactive development environment like CIDER.
Features
CIDER packs plenty of features. Here are some of them (in no particular order):
-
Interactive code evaluation
-
Powerful REPL
-
Code completion
-
Code reloading
-
Definition & documentation lookup
-
Enhanced error reporting
-
clojure.test
integration -
clojure.spec
integration -
Interactive debugger
-
ClojureScript support
And many many more… The rest of this manual will be exploring CIDER’s features in great detail.
CIDER in Action
Below you can see a typical CIDER session.
Here the user checked the documentation for clojure.core/merge
straight from the source buffer
and then jumped to a REPL buffer to try out something there.
Here’s also a video demo of CIDER’s essential functionality:
You can find several other demo videos on the Additional Resources page.
What’s Next?
So, what to do next? While you can peruse the documentation in whatever way you’d like, here are a few recommendations:
-
Install CIDER and get it up and running
-
Get familiar with interactive programming and cider-mode
-
Configure CIDER to your liking
-
Explore the additional packages that can make you more productive