diff --git a/after/plugin/lsp.lua b/after/plugin/lsp.lua index 85cc34eb..572b1aba 100644 --- a/after/plugin/lsp.lua +++ b/after/plugin/lsp.lua @@ -1,4 +1,5 @@ local lsp = require("lsp-zero") +local nvim_lsp = require('lspconfig') lsp.preset("recommended") @@ -19,6 +20,17 @@ lsp.configure('sumneko_lua', { } }) +lsp.configure('tsserver', { + root_dir = nvim_lsp.util.root_pattern("package.json"), + single_file_support = false, +}) + +lsp.configure('denols', { + root_dir = nvim_lsp.util.root_pattern("deno.jsonc"), + init_options = { + lint = true, + }, +}) local cmp = require('cmp') local cmp_select = {behavior = cmp.SelectBehavior.Select}