A Vim plugin that formats Clojure code using cljfmt via a REPL connection for faster formatting.
vim-cljfmt is a Vim plugin that provides integration with cljfmt, the Clojure code formatting tool. It formats Clojure and ClojureScript code directly within Vim by leveraging an existing REPL connection through vim-fireplace, eliminating the need to shell out to Leiningen and reducing formatting latency.
Clojure developers who use Vim as their primary editor and want fast, integrated code formatting without leaving their editing environment.
Developers choose vim-cljfmt for its REPL-based approach that avoids Leiningen startup overhead, keeping Vim responsive, and for its seamless integration with existing Vim workflows, including automatic formatting on save.
A Vim plugin for cljfmt, the Clojure formatting tool.
Open-Awesome is built by the community, for the community. Submit a project, suggest an awesome list, or help improve the catalog on GitHub.
Uses an existing vim-fireplace REPL to format code without shelling out to Leiningen, eliminating startup delays and keeping Vim responsive, as highlighted in the README's philosophy.
Formats the current buffer automatically on save by default, seamlessly enforcing code style within the editing workflow, with an option to disable it via g:clj_fmt_autosave.
Provides a :CljfmtRange command to format only visually selected code ranges, allowing precise formatting without affecting the entire file, as demonstrated in the usage section.
Allows passing cljfmt options through a Vim variable (g:clj_fmt_config), enabling tailored formatting rules like indentation and whitespace handling, as shown in the configuration examples.
Requires a stable vim-fireplace REPL connection; formatting fails if the REPL is unavailable, adding a single point of failure and complexity to the setup.
The first formatting call with a new REPL server incurs a delay as cljfmt loads, which the README admits can disrupt workflow for quick edits.
Depends on multiple prerequisites: vim-fireplace, cljfmt on the classpath, and a REPL connection, increasing initial configuration effort compared to standalone tools.