fix(neovim): use prettierd instead of deno's fmt

This commit is contained in:
Alexandre Cavalheiro 2025-01-21 03:47:05 -03:00
parent db2d6b9401
commit 23c4620908
Signed by: wizardlink
GPG key ID: A5767B54367CFBDF
2 changed files with 30 additions and 28 deletions

View file

@ -115,6 +115,7 @@ in
vscode-extensions.vadimcn.vscode-lldb
# Vue
prettierd
vue-language-server
# Svelte

View file

@ -11,33 +11,33 @@ return {
local null_ls = require("null-ls")
local helpers = require("null-ls.helpers")
local deno_fmt = helpers.make_builtin({
name = "deno_fmt",
filetypes = {
"angular",
"astro",
"css",
"html",
"javascript",
"json",
"jsonc",
"less",
"markdown",
"sass",
"scss",
"svelte",
"typescript",
"vue",
"yaml",
},
method = { null_ls.methods.FORMATTING },
generator_opts = {
command = "deno",
args = { "fmt", "--unstable-component", "-" },
to_stdin = true,
},
factory = helpers.formatter_factory,
})
-- local deno_fmt = helpers.make_builtin({
-- name = "deno_fmt",
-- filetypes = {
-- "angular",
-- "astro",
-- "css",
-- "html",
-- "javascript",
-- "json",
-- "jsonc",
-- "less",
-- "markdown",
-- "sass",
-- "scss",
-- "svelte",
-- "typescript",
-- "vue",
-- "yaml",
-- },
-- method = { null_ls.methods.FORMATTING },
-- generator_opts = {
-- command = "deno",
-- args = { "fmt", "--unstable-component", "-" },
-- to_stdin = true,
-- },
-- factory = helpers.formatter_factory,
-- })
-- Check supported formatters and linters
-- https://github.com/nvimtools/none-ls.nvim/tree/main/lua/null-ls/builtins/formatting
@ -52,7 +52,8 @@ return {
null_ls.builtins.formatting.csharpier,
null_ls.builtins.formatting.nixfmt,
null_ls.builtins.formatting.stylua,
deno_fmt,
--deno_fmt,
null_ls.builtins.formatting.prettierd,
}
return config -- return final config table
end,