From 7b972d581cbdffb2031a3cf46de7fe4ba658dea7 Mon Sep 17 00:00:00 2001 From: Santos Gallegos Date: Mon, 7 Sep 2020 11:41:37 -0500 Subject: Fold: update docs Document foldnestmax. --- README.md | 6 ++++-- doc/nvim-treesitter.txt | 3 +++ 2 files changed, 7 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index d5153ef31..3f3f7870f 100644 --- a/README.md +++ b/README.md @@ -299,14 +299,16 @@ EOF # Extra features -- Syntax based code folding +## Syntax based code folding ```vim set foldmethod=expr set foldexpr=nvim_treesitter#foldexpr() ``` -- Statusline indicator +This will respect your `foldnestmax` setting. + +## Statusline indicator ```vim echo nvim_treesitter#statusline(90) " 90 can be any length diff --git a/doc/nvim-treesitter.txt b/doc/nvim-treesitter.txt index 5afcd9069..e14a2ac15 100644 --- a/doc/nvim-treesitter.txt +++ b/doc/nvim-treesitter.txt @@ -551,6 +551,9 @@ To use it: > set foldmethod=expr set foldexpr=nvim_treesitter#foldexr() < + +This will respect your 'foldnestmax' setting. + Note: This is highly experimental, and folding can break on some types of edits. If you encounter such breakage, hiting `zx` should fix folding. In any case, feel free to open an issue with the reproducing steps. -- cgit v1.2.3-70-g09d2