aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorSteven Arcangeli <stevearc@stevearc.com>2023-09-12 20:48:25 -0700
committerSteven Arcangeli <stevearc@stevearc.com>2023-09-12 21:09:44 -0700
commit7568de69f42882df528c9ec2447784a0042dd59d (patch)
tree90901954be280c70dc106b15fe9f35238832364f
parent00a528818463b10d84699b2e0f4a960d5a4aeb5c (diff)
doc: add a features section to the README
-rw-r--r--README.md8
1 files changed, 8 insertions, 0 deletions
diff --git a/README.md b/README.md
index 81575e3..9cf1343 100644
--- a/README.md
+++ b/README.md
@@ -5,6 +5,7 @@ Lightweight yet powerful formatter plugin for Neovim
<!-- TOC -->
- [Requirements](#requirements)
+- [Features](#features)
- [Installation](#installation)
- [Setup](#setup)
- [Formatters](#formatters)
@@ -24,6 +25,13 @@ Lightweight yet powerful formatter plugin for Neovim
- Neovim 0.8+
+## Features
+
+- **Preserves extmarks and folds** - Most formatters replace the entire buffer, which clobbers extmarks and folds, and can cause the viewport and cursor to jump unexpectedly. Conform calculates minimal diffs and applies them using the built-in LSP format utilities.
+- **Fixes bad-behaving LSP formatters** - Some LSP servers are lazy and simply replace the entire buffer, leading to the problems mentioned above. Conform hooks into the LSP handler and turns these responses into proper piecewise changes.
+- **Enables range formatting for all formatters** - Since conform calculates minimal diffs, it can perform range formatting even if the underlying formatter doesn't support it.
+- **Simple API** - Conform exposes a simple, imperative API modeled after `vim.lsp.buf.format()`.
+
## Installation
conform.nvim supports all the usual plugin managers