Open Cliffback opened 6 months ago
Hello @Cliffback , I don't know this feature of nvim-tree. May be you can use nvim-tree.update_focused_file.exclude and check if it's float window like?
function(args)
return require("float-preview").is_float(args.buf)
end
Thanks for the reply! The split screen feature is just the one you showcase on the front page like this. Sorry if explanation was a bit misleading.
I basically just set up this, and get the error described above when using :NvimTreeToggle.
I'll check out the provided snippet
hey I got the same issue, fixed by adding modifying the keymap to quit:
-- add the close_wrap func
vim.keymap.set('n', 'q', close_wrap(api.tree.close), opts 'Close')
And same for ESC
When using nvim-tree.lua-float-preview with nvim-tree in the split screen configuration (like in #14), I get this when closing nvim-tree
the on_attach for nvim-tree is configured like this:
If I wrap the functions in the close_wrap, the error won't show up, but I have defined a global keymap for
:NvimTreeToggle
, and that will throw the error regardless. I can perphaps wrap the keymap with the close_wrap globally, but it still won't really solve the issue, just bypass it.Is there known solution to this?