Add diag at end of every line
This commit is contained in:
@@ -76,8 +76,20 @@ vim.keymap.set("n", "<leader>Y", "\"+Y")
|
||||
--
|
||||
|
||||
-- Disable built-in
|
||||
vim.diagnostic.config({ virtual_text = false } )
|
||||
-- vim.diagnostic.config({ virtual_text = false } )
|
||||
|
||||
-- Enable for the current line only
|
||||
-- End of line diagnostic for every error
|
||||
vim.diagnostic.config({
|
||||
virtual_text = {
|
||||
format = function(diagnostic)
|
||||
local lines = vim.split(diagnostic.message, '\n')
|
||||
return lines[1]
|
||||
end,
|
||||
virt_text_pos = 'right_align',
|
||||
suffix = ' ',
|
||||
},
|
||||
})
|
||||
|
||||
-- Enable all errors for the current line only
|
||||
vim.diagnostic.config({ virtual_lines = { only_current_line = true } })
|
||||
|
||||
|
||||
Reference in New Issue
Block a user