Function chorus.lsp.setup

chorus.lsp.setup(config: chorus.lsp.Config): nil

Configure LSP settings

Also available by invoking chorus.lsp as a function (or just lsp when using the default prelude).

May be called multiple times to configure different servers. Providing the same server or the global key more than once replaces the prior settings for that key.

Base (nvim-lspconfig), global, common, and specific settings are merged (as by vim.tbl_deep_extend) when applied. In addition, the following callbacks are merged so that all versions from the mentioned sources are run in order:

  • before_init

  • on_attach (including any keymap)

  • on_init

  • on_exit

  • on_error

Merging can be disabled by setting inherit = false for a particular language server.

Parameters:

config (chorus.lsp.Config) – Configuration