diff --git a/doc/nvim-treesitter.txt b/doc/nvim-treesitter.txt index 5e758513d..a55f50f7e 100644 --- a/doc/nvim-treesitter.txt +++ b/doc/nvim-treesitter.txt @@ -74,9 +74,13 @@ Each module corresponds to an entry in the dictionary passed to the EOF < -All modules share some common options, like `enable` and `disable`. +All modules share some common options, like `enable`, `disable`, and `cond`. When `enable` is `true` this will enable the module for all supported languages, if you want to disable the module for some languages you can pass a list to the `disable` option. +For more fine-grained control, `cond` takes a function and whenever it returns +`false` the module is disabled for that buffer. +The `cond` function is called once when a module starts in a buffer and +received the language and the buffer number as arguments. > lua < 50000) + end, }, } EOF