kosayoda / nvim-lightbulb

VSCode 💡 for neovim's built-in LSP.
MIT License
783 stars 27 forks source link

Takes ~4 seconds to show lightbulb #38

Closed Integralist closed 2 years ago

Integralist commented 2 years ago

👋🏻 This plugin used to work fine when I was using vimscript, but I recently migrated to lua (https://github.com/Integralist/dotfiles/tree/main/.config/nvim) and since then I've discovered that it takes 4 seconds (consistently) for every line to show/hide the lightbulb.

I'm using the latest version of ...well, everything :-) so let me know if there's any particular details that might help identify the problem.

Many thanks!

Integralist commented 2 years ago

This looks to be a default setting for vim.o.updatetime and setting it to 1000 seems to help.

kosayoda commented 2 years ago

This looks to be a default setting for vim.o.updatetime and setting it to 1000 seems to help.

Yes, that setting governs CursorHold update frequency. I also highly recommend https://github.com/antoinemadec/FixCursorHold.nvim to work around certain existing issues in neovim.