mirror of
https://github.com/pojokcodeid/nvim-lazy.git
synced 2025-06-22 00:49:01 +02:00
add: create new config for denols
This commit is contained in:
parent
4bf3cb08ad
commit
02ea286c83
2 changed files with 37 additions and 2 deletions
35
lua/user/lsp/settings/denols.lua
Normal file
35
lua/user/lsp/settings/denols.lua
Normal file
|
@ -0,0 +1,35 @@
|
|||
return {
|
||||
-- add cmd
|
||||
cmd = { "deno", "lsp" },
|
||||
-- add file type support
|
||||
filetypes = {
|
||||
"javascript",
|
||||
"javascriptreact",
|
||||
"javascript.jsx",
|
||||
"typescript",
|
||||
"typescriptreact",
|
||||
"typescript.tsx",
|
||||
},
|
||||
-- add root dir support
|
||||
root_dir = require("lspconfig.util").root_pattern(
|
||||
"package.json",
|
||||
"tsconfig.json",
|
||||
"jsconfig.json",
|
||||
"deno.json",
|
||||
"deno.jsonc",
|
||||
".git"
|
||||
),
|
||||
-- add settings
|
||||
settings = {
|
||||
deno = {
|
||||
enable = true,
|
||||
suggest = {
|
||||
imports = {
|
||||
hosts = {
|
||||
["https://deno.land"] = true,
|
||||
},
|
||||
},
|
||||
},
|
||||
},
|
||||
},
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue