add deno support

This commit is contained in:
xfy
2024-10-11 09:04:19 +08:00
parent 3ff83134ce
commit 58a2349d3b
4 changed files with 23 additions and 7 deletions

View File

@ -42,8 +42,8 @@ return {
opts.desc = "Show buffer diagnostics"
map("n", "<leader>D", "<cmd>Telescope diagnostics bufnr=0<CR>", opts) -- show diagnostics for file
opts.desc = "Show line diagnostics"
map("n", "<leader>d", vim.diagnostic.open_float, opts) -- show diagnostics for line
-- opts.desc = "Show line diagnostics"
-- map("n", "<leader>d", vim.diagnostic.open_float, opts) -- show diagnostics for line
opts.desc = "Go to previous diagnostic"
map("n", "[d", vim.diagnostic.goto_prev, opts) -- jump to previous diagnostic in buffer
@ -98,6 +98,13 @@ return {
},
})
end,
["denols"] = function()
lspconfig["denols"].setup({
-- on_attach = on_attach,
capabilities = capabilities,
root_dir = lspconfig.util.root_pattern("deno.json", "deno.jsonc"),
})
end,
["vtsls"] = function()
lspconfig["vtsls"].setup(require("rua.config.vtsls"))
map("n", "<leader>co", "<cmd> OrganizeImports <CR>", { desc = "Organize imports" })