Skip to content

Conversation

iton0
Copy link
Contributor

@iton0 iton0 commented Jul 24, 2024

  • moved lazydev and luvit-meta into their own specs to enable
    lazy-loading

Based on this discussion lazydev.nvim and luvit-meta will always load when nvim-lspconfig loads.

@abeldekat
Copy link
Contributor

Currently both lazydev.nvim and luvit-meta are a dependency of nvim-lspconfig, a start plugin. As such, they always load.

Those plugins are only relevant for the lua language though. Perhaps they should be moved from the dependencies section into the main spec.

See Folke's example

@iton0
Copy link
Contributor Author

iton0 commented Jul 24, 2024

@abeldekat something more along the lines of this:

  -- LSP Plugins
  {
    -- `lazydev` configures Lua LSP for your Neovim config, runtime and plugins
    -- used for completion, annotations and signatures of Neovim apis
    'folke/lazydev.nvim',
    ft = 'lua',
    opts = {
      library = {
        -- Load luvit types when the `vim.uv` word is found
        { path = 'luvit-meta/library', words = { 'vim%.uv' } },
      },
    },
  },
  { 'Bilal2453/luvit-meta', lazy = true },
  { 
    -- Main LSP Configuration
    'neovim/nvim-lspconfig',
    dependencies = {
      -- Automatically install LSPs and related tools to stdpath for Neovim
      { 'williamboman/mason.nvim', config = true }, -- NOTE: Must be loaded before dependants
...

@abeldekat
Copy link
Contributor

Yes, that's what I was thinking about.

- moved lazydev and luvit-meta into their own specs to enable
  lazy-loading

Based on this [discussion](folke/lazy.nvim#610 (comment)) lazydev.nvim and luvit-meta will always load when nvim-lspconfig loads.
@iton0 iton0 changed the title refactor: remove lazy-loading specs for lsp dependencies refactor: remove lazydev and luvit-meta as lsp dependencies Jul 24, 2024
@feoh
Copy link
Collaborator

feoh commented Jul 28, 2024

I don't have a problem with this, but it's a sizable code change.

Are you willing to monitor kickstart.nvim issues and help with responding if this blows up people's configurations?

Sorry to be so blunt and put strings around willingness to merge, but I have a life to lead outside this project and my tiny brain has limits :)

@iton0
Copy link
Contributor Author

iton0 commented Jul 28, 2024

I know @folke is on vacation right now, but maybe after he returns, he can give better insight on whether this will break the config. @feoh, does that sound good?

@feoh feoh merged commit fd66454 into nvim-lua:master Jul 28, 2024
@feoh
Copy link
Collaborator

feoh commented Jul 28, 2024

I think I'm good. Merged.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants