conform.nvim is a formatter plugin for Neovim that preserves extmarks and folds while applying code formatting changes.
The plugin solves the problem that most formatters replace entire buffers, which destroys extmarks, folds, and can cause unexpected viewport and cursor jumps. Conform calculates minimal diffs between the original and formatted code, then applies only those changes using Neovim's built-in LSP format utilities. This approach also allows it to intercept and fix LSP servers that lazily replace entire buffers, and enables range formatting even for formatters that do not natively support it. The tool can format embedded code blocks inside markdown files and similar documents through injected language formatting.
Anyone adopting conform.nvim should know it requires Neovim 0.10 or later. The plugin exposes a simple, imperative API modeled after vim.lsp.buf.format(), making it straightforward to integrate into existing workflows. It supports all major plugin managers and can optionally set up format-on-save automation. The tool is well-suited for developers who want reliable formatting without the side effects of buffer replacement, particularly those working with complex files where preserving folds and extmarks matters. A ConformInfo command provides visibility into configured and available formatters plus debugging information.
The project shows consistent maintenance with regular updates addressing edge cases and formatter compatibility. Development activity demonstrates responsiveness to user-reported issues and steady expansion of supported formatters. The codebase maintains focus on the core diff-based formatting approach rather than feature sprawl.