add: update config ufo

This commit is contained in:
asep.komarudin 2024-03-28 18:40:37 +07:00
parent cd9dcc6c26
commit 5518885b31

View file

@ -17,7 +17,7 @@ return {
end,
},
},
event = "BufRead",
event = "BufReadPost",
config = function()
vim.o.foldcolumn = "1" -- '0' is not bad
vim.o.foldlevel = 99 -- Using ufo provider need a large value, feel free to decrease the value
@ -28,7 +28,7 @@ return {
-- these are "extra", change them as you like
vim.keymap.set("n", "zR", require("ufo").openAllFolds)
vim.keymap.set("n", "zM", require("ufo").closeAllFolds)
vim.cmd("highlight FoldColumn guifg=" .. vim.fn.synIDattr(vim.fn.synIDtrans(vim.fn.hlID("Comment")), "fg"))
-- Option 3: treesitter as a main provider instead
-- Only depend on `nvim-treesitter/queries/filetype/folds.scm`,
-- performance and stability are better than `foldmethod=nvim_treesitter#foldexpr()`