feat: add keymap to swap virtual_text and virtual_lines for diagnostic

This commit is contained in:
2025-10-13 23:49:21 +02:00
parent f92f71ec39
commit cdc02fc3e4

8
plugin/diagswap.lua Normal file
View File

@@ -0,0 +1,8 @@
local state = true
local function swap()
vim.diagnostic.config({ virtual_text = not state, virtual_lines = state })
state = not state
end
vim.keymap.set("n", "<leader>dt", swap)