28 lines
425 B
Lua
28 lines
425 B
Lua
|
local present, nvim_treesitter = pcall(require, "nvim-treesitter.configs")
|
||
|
if not present then
|
||
|
return
|
||
|
end
|
||
|
|
||
|
nvim_treesitter.setup {
|
||
|
highlight = {
|
||
|
enable = true,
|
||
|
additional_vim_regex_highlighting = true,
|
||
|
},
|
||
|
matchup = {
|
||
|
enable = true,
|
||
|
},
|
||
|
indent = {
|
||
|
enable = true
|
||
|
},
|
||
|
autotag = {
|
||
|
enable = true
|
||
|
}
|
||
|
}
|
||
|
|
||
|
vim.cmd
|
||
|
[[
|
||
|
set foldmethod=expr
|
||
|
set foldexpr=nvim_treesitter#foldexpr()
|
||
|
set foldlevel=99
|
||
|
]]
|