added support for Deno

This commit was merged in pull request #3.
This commit is contained in:
2026-07-07 14:47:11 -06:00
parent f25365eaec
commit e892db65cd
+44
View File
@@ -0,0 +1,44 @@
-- Deno Support
return {
-- Mason
{
"mason-org/mason.nvim",
opts = function(_, opts)
opts.ensure_installed = opts.ensure_installed or {}
vim.list_extend(opts.ensure_installed, { "deno" })
end,
},
-- LSP Config
{
"neovim/nvim-lspconfig",
opts = {
servers = {
denols = {
root_markers = { "deno.json", "deno.jsonc" },
},
},
},
},
-- Conform
{
"stevearc/conform.nvim",
opts = {
formatters_by_ft = {
javascript = { "deno_fmt", "prettier", stop_after_first = true },
javascriptreact = { "deno_fmt", "prettier", stop_after_first = true },
typescript = { "deno_fmt", "prettier", stop_after_first = true },
typescriptreact = { "deno_fmt", "prettier", stop_after_first = true },
},
formatters = {
deno_fmt = {
condition = function(ctx)
return vim.fs.find({ "deno.json", "deno.jsonc" }, { path = ctx.filename, upward = true })[1] ~= nil
end,
},
},
},
},
}