Skip to content

Commit 2ba0738

Browse files
committed
fix: deprecated diagnostic jumping config
1 parent 16dd8f5 commit 2ba0738

File tree

1 file changed

+6
-1
lines changed

1 file changed

+6
-1
lines changed

init.lua

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -184,7 +184,12 @@ vim.diagnostic.config {
184184
virtual_lines = false, -- Text shows up underneath the line, with virtual lines
185185

186186
-- Auto open the float, so you can easily read the errors when jumping with `[d` and `]d`
187-
jump = { float = true },
187+
jump = {
188+
on_jump = function(diagnostic, _)
189+
if not diagnostic then return end
190+
vim.diagnostic.open_float { focus = false }
191+
end,
192+
},
188193
}
189194

190195
vim.keymap.set('n', '<leader>q', vim.diagnostic.setloclist, { desc = 'Open diagnostic [Q]uickfix list' })

0 commit comments

Comments
 (0)