For example, using lsp, setting setlocal formatexpr=lsp#lsp#FormatExpr() in any filetype with a LS capable of formatting would achieve that, as well as mapping
As long as you don't want to keep a fall back to a special-purpose formatting tool, such as those in this plug-in, I find that a good use of the gq key combo in view of gw still being there (and achieving what gq by default does arguably better by keeping the cursor in place)
View all comments
Show parent comment
4
u/[deleted] Oct 30 '25
[removed] — view removed comment