ecosse3 / nvim

A non-minimal Neovim config built to work most efficiently with Frontend Development

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

why does it hide the imports?

peteblank opened this issue · comments

So i like this don't get me wrong but I can't use it if its going to start hiding imports and/or deleting them.

This is a nvim-ufo plugin. You can remove it.

First remove it from plugins.lua:

nvim/lua/config/plugins.lua

Lines 418 to 426 in 69747da

{
"kevinhwang91/nvim-ufo",
dependencies = "kevinhwang91/promise-async",
config = function()
vim.keymap.set("n", "zR", require("ufo").openAllFolds)
vim.keymap.set("n", "zM", require("ufo").closeAllFolds)
vim.keymap.set("n", "zr", require("ufo").openFoldsExceptKinds)
end,
},

Then in lsp/setup.lua (in require too):

nvim/lua/lsp/setup.lua

Lines 137 to 140 in 69747da

require("ufo").setup({
fold_virt_text_handler = ufo_config_handler,
close_fold_kinds = { "imports" },
})

And jest leave vim.lsp.buf.hover() in keymappings.lua:

keymap("n", "K", function()
local winid = require("ufo").peekFoldedLinesUnderCursor()
if not winid then
vim.lsp.buf.hover()
end
end)