You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: README.md
+21-3Lines changed: 21 additions & 3 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -53,6 +53,24 @@ At the moment, you have two options:
53
53
54
54
For more information, refer to the readme and documentation of the respective plugins.
55
55
56
+
## Folding
57
+
58
+
You can let the language server automatically handle folding for you. To enable this, you have to set `'foldmethod'`, `'foldexpr'` and (optionally) `'foldtext'`:
59
+
60
+
```vim
61
+
set foldmethod=expr
62
+
\ foldexpr=lsp#ui#vim#folding#foldexpr()
63
+
\ foldtext=lsp#ui#vim#folding#foldtext()
64
+
```
65
+
66
+
If you would like to disable folding globally, you can add this to your configuration:
67
+
68
+
```vim
69
+
let g:lsp_fold_enabled = 0
70
+
```
71
+
72
+
Also see `:h vim-lsp-folding`.
73
+
56
74
## Supported commands
57
75
58
76
**Note:**
@@ -146,11 +164,11 @@ Virtual text will use the same highlight groups as signs feature.
146
164
147
165
### Highlight references
148
166
149
-
References to the symbol under the cursor are highlighted by default. To
150
-
disable, set in your configuration:
167
+
Highlight references to the symbol under the cursor. To enable, set in your
168
+
configuration:
151
169
152
170
```viml
153
-
let g:lsp_highlight_references_enabled = 0
171
+
let g:lsp_highlight_references_enabled = 1
154
172
```
155
173
156
174
To change the style of the highlighting, you can set or link the `lspReference`
0 commit comments