Skip to content
This repository was archived by the owner on Jul 29, 2023. It is now read-only.

Commit 7753505

Browse files
authored
Add example on how to use the plugin with Json and MD (#367)
With disabled conceal for these file types
1 parent 5617a1c commit 7753505

File tree

1 file changed

+26
-1
lines changed

1 file changed

+26
-1
lines changed

README.md

Lines changed: 26 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -71,7 +71,8 @@ each indent level has a distinct character.
7171

7272
This plugin enables the Vim `conceal` feature which automatically hides stretches of text based on syntax highlighting. This setting will apply to all syntax items.
7373

74-
For example, users utilizing the built in json.vim syntax file will no longer see quotation marks in their JSON files.
74+
For example, users utilizing the built in json.vim syntax file will no longer see quotation marks in their JSON files
75+
(see below how to disable conceal for JSON without disabling indentLine).
7576

7677
indentLine will overwrite your "concealcursor" and "conceallevel" with default value:
7778

@@ -90,6 +91,30 @@ let g:indentLine_setConceal = 0
9091
See the [VIM Reference Manual](http://vimdoc.sourceforge.net/htmldoc/version7.html#new-conceal) for more information on the `conceal` feature.
9192

9293

94+
**Disabling conceal for JSON and Markdown without disabling indentLine plugin**
95+
96+
Even though this plugin requires conceal to be enabled for it to work, it is
97+
possible to disable conceal for JSON and Markdown files and still get the
98+
indentLine plugin to show indent lines for those files.
99+
100+
Builtin [json.vim](https://github.com/vim/vim/blob/master/runtime/syntax/json.vim)
101+
and [markdown.vim](https://github.com/vim/vim/blob/master/runtime/syntax/markdown.vim)
102+
syntax allow disabling conceal by setting the following vars:
103+
104+
* JSON
105+
```vim
106+
let g:vim_json_conceal=0
107+
```
108+
109+
* Markdown
110+
```vim
111+
let g:markdown_syntax_conceal=0
112+
```
113+
114+
If you use other syntax plugins for those file types, you will need to check
115+
their docs, as they may use different vars or have different ways to configure
116+
this.
117+
93118
**Disable by default**
94119
```vim
95120
let g:indentLine_enabled = 0

0 commit comments

Comments
 (0)