caio.co/de/dotfiles

go: fold with treesitter, disabled by default

Id
2687822aa9e3952d2917db01b98db93655cd0fec
Author
Caio
Commit time
2022-05-10T10:22:36+02:00

Modified config/nvim/ftplugin/go.vim

@@ -1,1 +1,6
setlocal noexpandtab shiftwidth=4 softtabstop=4 tabstop=4 nolist
+
+" if has_treesitter
+setlocal nofoldenable
+setlocal foldmethod=expr
+setlocal foldexpr=nvim_treesitter#foldmethod()