fixed deprecated format call
This commit is contained in:
parent
5f357b0db5
commit
5ad1c4be90
@ -62,7 +62,7 @@ local on_attach = function(client, bufnr)
|
||||
|
||||
-- Set some keybinds conditional on server capabilities
|
||||
if client.server_capabilities.documentFormattingProvider then
|
||||
buf_set_keymap('n', '<space>f', '<cmd>lua vim.lsp.buf.formatting()<CR>', opts)
|
||||
buf_set_keymap('n', '<space>f', '<cmd>lua vim.lsp.buf.format{async=true}<CR>', opts)
|
||||
end
|
||||
if client.server_capabilities.documentRangeFormattingProvider then
|
||||
buf_set_keymap('v', '<space>f', '<esc><cmd>lua vim.lsp.buf.range_formatting()<CR>', opts)
|
||||
|
Loading…
x
Reference in New Issue
Block a user