style: auto-format

main
mandlm 2023-04-11 07:40:22 +02:00
parent d443c729a9
commit 94e81693d9
Signed by: mandlm
GPG Key ID: 4AA25D647AA54CC7
1 changed files with 7 additions and 4 deletions

View File

@ -6,9 +6,13 @@ local on_attach = function(client, bufnr)
end end
local function format_buffer() local function format_buffer()
vim.lsp.buf.format({ timeout_ms = 3000, async = false, filter = function(formatter) vim.lsp.buf.format({
return formatter.name ~= "tsserver" and formatter.name ~= "volar" timeout_ms = 3000,
end }) async = false,
filter = function(formatter)
return formatter.name ~= "tsserver" and formatter.name ~= "volar"
end
})
end end
local telescope = require("telescope.builtin") local telescope = require("telescope.builtin")
@ -131,7 +135,6 @@ null_ls.setup({
null_ls.builtins.diagnostics.eslint_d, null_ls.builtins.diagnostics.eslint_d,
null_ls.builtins.diagnostics.tsc, null_ls.builtins.diagnostics.tsc,
}, },
on_attach = on_attach, on_attach = on_attach,
}) })