nixos/config/nvim/lua/lsp/formatting.lua

10 lines
239 B
Lua

local lsp_formatting = function(bufnr)
vim.lsp.buf.format {
bufnr = bufnr,
timeout_ms = 2000,
async = true,
filter = function(client) return client.name == "null-ls" end,
}
end
return lsp_formatting